本文整理汇总了PHP中yii\bootstrap\Alert::end方法的典型用法代码示例。如果您正苦于以下问题:PHP Alert::end方法的具体用法?PHP Alert::end怎么用?PHP Alert::end使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类yii\bootstrap\Alert
的用法示例。
在下文中一共展示了Alert::end方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
<?php
} else {
?>
<?php
\yii\bootstrap\Alert::begin(['options' => ['class' => 'alert-info']]);
?>
<p><?php
echo \Yii::t('app', 'You can choose the suitable solution for your project and install it.');
?>
</p>
<p><?php
echo \Yii::t('app', 'Future versions will be integrated {market} here. For now, simply click the link below.', ['market' => \Yii::t('app', 'Marketplace')]);
?>
</p>
<?php
\yii\bootstrap\Alert::end();
?>
<div class="sx-marketplace">
<a href="http://marketplace.cms.skeeks.com/" target="_blank">Marketplace.CMS.SkeekS.com</a> — <?php
echo \Yii::t('app', 'catalog of available solutions');
?>
</div>
<?php
$this->registerCss(<<<CSS
.sx-marketplace
{
text-align: center;
font-size: 30px;
color: #e74c3c;
示例2: beforeValidate
?>
<div id="main-content">
<div class="change-password">
<div class="wrapper-150">
<h1 class="page-title">Change Password</h1>
<?php
if ($success) {
Alert::begin([
'options' => [
'class' => 'alert-success',
],
]);
echo 'Password changed successfully.';
Alert::end();
}
?>
<div class="one-column help-bg-gray pdt-one-column" >
<?php
$js = 'function beforeValidate(form) {if ( form.data("cancel") {this.validateOnSubmit = false;this.beforeValidate = "";form.submit();return false;}return true;}';
$form = ActiveForm::begin([
'options' => ['class' => 'form-horizontal'],
'fieldConfig' => [
'template' => '<div class="control-group">{label}<div class="f-inline-size">{input}</div><div class=\"col-lg-8\">{error}</div></div>',
],
]); ?>
<?= $form->field($model, 'oldPassword')->textInput(['maxlength' => 32,
'class' => 'uborder help-40percent'])->label('Old Password', ['class' => 'control-label-f'])->passwordInput() ?>