本文整理汇总了PHP中yii\helpers\Html::link方法的典型用法代码示例。如果您正苦于以下问题:PHP Html::link方法的具体用法?PHP Html::link怎么用?PHP Html::link使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类yii\helpers\Html
的用法示例。
在下文中一共展示了Html::link方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
<div class="view">
<b><?php
echo \yii\helpers\Html::encode($data->getAttributeLabel('num'));
?>
:</b>
<?php
echo \yii\helpers\Html::link(\yii\helpers\Html::encode($data->num), array('view', 'id' => $data->num));
?>
<br />
<b><?php
echo \yii\helpers\Html::encode($data->getAttributeLabel('name'));
?>
:</b>
<?php
echo \yii\helpers\Html::encode($data->company);
?>
<br />
<b><?php
echo \yii\helpers\Html::encode($data->getAttributeLabel('type'));
?>
:</b>
<?php
echo \yii\helpers\Html::encode($data->type);
?>
<br />
<b><?php
echo \yii\helpers\Html::encode($data->getAttributeLabel('id6111'));
示例2: array
<?php
$this->params["breadcrumbs"] = array('Bank Names' => array('index'), 'Manage');
$this->params["menu"] = array(array('label' => 'List BankName', 'url' => array('index')), array('label' => 'Create BankName', 'url' => array('create')));
?>
<h1>Manage Bank Names</h1>
<p>
You may optionally enter a comparison operator (<b><</b>, <b><=</b>, <b>></b>, <b>>=</b>, <b><></b>
or <b>=</b>) at the beginning of each of your search values to specify how the comparison should be done.
</p>
<?php
echo \yii\helpers\Html::link('Advanced Search', '#', array('class' => 'search-button btn'));
?>
<div class="search-form" style="display:none">
<?php
$this->renderPartial('_search', array('model' => $model));
?>
</div><!-- search-form -->
<?php
echo app\widgets\GridView::widget(array('id' => 'bank-name-grid', 'dataProvider' => $model->dp(), 'columns' => array('id', 'name', array('class' => 'yii\\grid\\ActionColumn'))));
示例3:
<p>
Questo messaggio contiene una password a singolo utilizzo.<br>
É stata inviata da <?php
echo \yii\helpers\Html::link(Yii::$app->name, $siteUrl);
?>
. Se non avete eseguito voi la richiesta ignorate questa mail o contattate l'amministratore.
</p>
<p>Inserite il seguente codice nella pagina dai cui è stato richiesto:</p>
<h3><?php
echo $code;
?>
</h3>