當前位置: 首頁>>代碼示例>>PHP>>正文


PHP AssetsHelper::getImageTagForBoolean方法代碼示例

本文整理匯總了PHP中AssetsHelper::getImageTagForBoolean方法的典型用法代碼示例。如果您正苦於以下問題:PHP AssetsHelper::getImageTagForBoolean方法的具體用法?PHP AssetsHelper::getImageTagForBoolean怎麽用?PHP AssetsHelper::getImageTagForBoolean使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在AssetsHelper的用法示例。


在下文中一共展示了AssetsHelper::getImageTagForBoolean方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: array

		<h1><?php 
echo CHtml::encode($model->title);
?>
</h1>
	</div>
	<div id="commandBlock">
		<ul class="menu">
			<li class="list">
				<?php 
echo CHtml::link(Yii::t('app', 'Back to list'), array('/news/news/admin', 'ajax' => 'adminGridView', 'page' => Yii::app()->session->get('admin_current_page'), 'filter' => Yii::app()->session->get('admin_current_filter') ? 1 : 0));
?>
			</li>
			<li class="create">
				<?php 
echo CHtml::link(Yii::t('NewsModule.labels', 'Add a news'), array('/news/news/create'));
?>
			</li>
			<li class="update">
				<?php 
echo CHtml::link(Yii::t('NewsModule.labels', 'Update this news'), array('/news/news/update', "id" => $model->id));
?>
			</li>
		</ul>
	</div>
	<div class="clear"></div>
</div>
<div id="content_section">
	<?php 
$this->widget('zii.widgets.CDetailView', array('data' => $model, 'attributes' => array(array('label' => Yii::t('app', 'Enabled'), 'value' => AssetsHelper::getImageTagForBoolean($model->enabled), 'type' => 'html'), array('label' => Yii::t('app', 'Created at'), 'name' => 'created_at', 'type' => 'datetime'), array('label' => Yii::t('app', 'Updated at'), 'name' => 'updated_at', 'type' => 'datetime'), array('label' => '', 'value' => "<hr/>", 'type' => 'html'), array('label' => Yii::t('NewsModule.labels', 'Event date'), 'name' => 'event_date', 'type' => 'datetime'), array('label' => Yii::t('app', 'Title'), 'value' => $model->getTranslation()->title), array('label' => Yii::t('app', 'Description'), 'value' => $model->getTranslation()->description), array('label' => Yii::t('app', 'Keywords'), 'value' => $model->getTranslation()->keywords), array('label' => Yii::t('NewsModule.labels', 'Tags'), 'value' => implode(', ', $model->getTagsNames())), array('label' => Yii::t('NewsModule.labels', 'Translations'), 'value' => implode(', ', $model->getLanguagesCodes())))));
?>
</div>
開發者ID:ChristopheBrun,項目名稱:hLib,代碼行數:31,代碼來源:view.php

示例2: array

		<h1><?php 
echo CHtml::encode($model->name);
?>
</h1>
	</div>
	<div id="commandBlock">
		<ul class="menu">
			<li class="list">
				<?php 
echo CHtml::link(Yii::t('app', 'Back to list'), array('/admin/language/admin', 'ajax' => 'adminGridView', 'page' => Yii::app()->session->get('admin_current_page'), 'filter' => Yii::app()->session->get('admin_current_filter') ? 1 : 0));
?>
			</li>
			<li class="create">
				<?php 
echo CHtml::link(Yii::t('AdminModule.labels', 'Add a language'), array('/admin/language/create'));
?>
			</li>
			<li class="update">
				<?php 
echo CHtml::link(Yii::t('AdminModule.labels', 'Update this language'), array('/admin/language/update', "id" => $model->id));
?>
			</li>
		</ul>
	</div>
	<div class="clear"></div>
</div>
<div id="content_section">
	<?php 
$this->widget('zii.widgets.CDetailView', array('data' => $model, 'attributes' => array(array('name' => 'enabled', 'value' => AssetsHelper::getImageTagForBoolean($model->enabled), 'type' => 'html'), array('name' => 'created_at', 'type' => 'datetime'), array('name' => 'updated_at', 'type' => 'datetime'), 'code', 'name')));
?>
</div>
開發者ID:ChristopheBrun,項目名稱:hLib,代碼行數:31,代碼來源:view.php

示例3: implode

		<b><?php 
echo Yii::t('app', 'Texts');
?>
:</b>
		<?php 
echo implode(', ', $data->getTextsNames());
?>
		<br/>
	</div>
	<div class="adminData">
		<b><?php 
echo CHtml::encode($data->getAttributeLabel('enabled'));
?>
:</b>
		<?php 
echo AssetsHelper::getImageTagForBoolean($data->enabled);
?>
		<br/>

		<b><?php 
echo CHtml::encode($data->getAttributeLabel('created_at'));
?>
:</b>
		<?php 
echo CHtml::encode(CodeGeneratorHelper::getFormattedValue('datetime', $data->created_at));
?>
		<br/>

		<b><?php 
echo CHtml::link($data->getAttributeLabel('updated_at'), array($this->id . '/update/id/' . $data->id));
?>
開發者ID:ChristopheBrun,項目名稱:hLib,代碼行數:31,代碼來源:_view.php

示例4: array

		<h1><?php 
echo CHtml::encode($model->title);
?>
</h1>
	</div>
	<div id="commandBlock">
		<ul class="menu">
			<li class="list">
				<?php 
echo CHtml::link(Yii::t('app', 'Back to list'), array('/webPages/webPage/admin', 'ajax' => 'adminGridView', 'page' => Yii::app()->session->get('admin_current_page'), 'filter' => Yii::app()->session->get('admin_current_filter') ? 1 : 0));
?>
			</li>
			<li class="create">
				<?php 
echo CHtml::link(Yii::t('WebPagesModule.labels', 'Add a web page'), array('/webPages/webPage/create'));
?>
			</li>
			<li class="update">
				<?php 
echo CHtml::link(Yii::t('WebPagesModule.labels', 'Update this web page'), array('/webPages/webPage/update', "id" => $model->id));
?>
			</li>
		</ul>
	</div>
	<div class="clear"></div>
</div>
<div id="content_section">
	<?php 
$this->widget('zii.widgets.CDetailView', array('data' => $model, 'attributes' => array(array('name' => 'enabled', 'value' => AssetsHelper::getImageTagForBoolean($model->enabled), 'type' => 'html'), array('name' => 'created_at', 'type' => 'datetime'), array('name' => 'updated_at', 'type' => 'datetime'), 'name', 'title', 'description', 'keywords', array('name' => 'webTexts', 'value' => implode(', ', $model->getTextsNames())))));
?>
</div>
開發者ID:ChristopheBrun,項目名稱:hLib,代碼行數:31,代碼來源:view.php


注:本文中的AssetsHelper::getImageTagForBoolean方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。