当前位置: 首页>>代码示例>>PHP>>正文


PHP TbHtml::btn方法代码示例

本文整理汇总了PHP中TbHtml::btn方法的典型用法代码示例。如果您正苦于以下问题:PHP TbHtml::btn方法的具体用法?PHP TbHtml::btn怎么用?PHP TbHtml::btn使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在TbHtml的用法示例。


在下文中一共展示了TbHtml::btn方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: render

 /**
  * Returns this button.
  * @return string the rendering result.
  */
 public function render()
 {
     $attributes = $this->attributes;
     $attributes['name'] = $this->name;
     if (isset(self::$coreTypes[$this->type])) {
         $type = self::$coreTypes[$this->type];
         return TbHtml::btn($type, $this->label, $attributes);
     } else {
         return $this->getParent()->getOwner()->widget($this->type, $attributes, true);
     }
 }
开发者ID:mfavetti,项目名称:LimeSurvey,代码行数:15,代码来源:TbFormButtonElement.php

示例2: array

<div class="row">
    <div class="span6 offset3 well">
        <h3 class="text-center"><?php 
echo Yii::t('app', 'Recovery user password');
?>
</h3>
        <?php 
$form = $this->beginWidget('bootstrap.widgets.TbActiveForm', array('id' => 'recovery-password-form', 'layout' => TbHtml::FORM_LAYOUT_HORIZONTAL));
?>
        <p class="muted text-center">
            <?php 
echo Yii::t('app', 'Please input your email address below, you will be sent a link to reset your password.');
?>

            <?php 
echo $form->errorSummary($model);
?>
            <?php 
echo $form->textFieldControlGroup($model, 'email', array('class' => 'span4', 'placeholder' => Yii::t('app', 'email')));
?>

            <?php 
echo TbHtml::formActions(array(TbHtml::submitButton(Yii::t('user', 'Recovery password'), array('color' => TbHtml::BUTTON_COLOR_SUCCESS)), TbHtml::btn(TbHtml::BUTTON_TYPE_LINK, Yii::t('user', 'Remember password?'), array('color' => TbHtml::BUTTON_COLOR_LINK, 'url' => '/user/login'))));
?>

            <?php 
$this->endWidget();
?>
    </div>
</div><!-- form -->
开发者ID:latik,项目名称:yii-user,代码行数:30,代码来源:passrecovery.php

示例3: array

        <?php 
echo $form->errorSummary($model);
?>

        <?php 
echo $form->textFieldControlGroup($model, 'username', array('placeholder' => Yii::t('app', 'username')));
?>
        <?php 
echo $form->textFieldControlGroup($model, 'email', array('placeholder' => Yii::t('app', 'email')));
?>
        <?php 
echo $form->passwordFieldControlGroup($model, 'password', array('placeholder' => Yii::t('app', 'password')));
?>

        <?php 
echo TbHtml::formActions(array(TbHtml::submitButton(Yii::t('user', 'Sign Up!'), array('color' => TbHtml::BUTTON_COLOR_SUCCESS))));
?>
        <?php 
$this->endWidget();
?>

        <div class="well">
            <div class="span3 offset1">
                <?php 
echo TbHtml::btn(TbHtml::BUTTON_TYPE_LINK, Yii::t('user', 'Already registered?'), array('color' => TbHtml::BUTTON_COLOR_PRIMARY, 'url' => '/user/login'));
?>
            </div>
        </div>
    </div>
</div>
开发者ID:latik,项目名称:yii-user,代码行数:30,代码来源:register.php

示例4: render

 /**
  * Returns this button.
  * @return string the rendering result.
  */
 public function render()
 {
     return TbHtml::btn($this->type, $this->label, $this->attributes);
 }
开发者ID:LumbaJack,项目名称:Mercado-BTX,代码行数:8,代码来源:TbFormButtonElement.php

示例5: array

//echo $form->errorSummary($model);
?>
        <?php 
echo $form->textFieldControlGroup($model, 'username', array('class' => 'span3', 'placeholder' => Yii::t('user', 'username or email')));
?>
        <?php 
echo $form->passwordFieldControlGroup($model, 'password', array('class' => 'span3', 'placeholder' => Yii::t('user', 'password')));
?>

        <?php 
echo TbHtml::formActions(array(TbHtml::submitButton(Yii::t('user', 'Log In'), array('color' => TbHtml::BUTTON_COLOR_PRIMARY)), TbHtml::btn(TbHtml::BUTTON_TYPE_LINK, Yii::t('user', 'Forgot password?'), array('color' => TbHtml::BUTTON_COLOR_LINK, 'url' => '/user/passrecovery'))));
?>

        <?php 
$this->endWidget();
?>

        <div class='well'>
            <div class="span2"><?php 
echo Yii::t('user', 'New user?');
?>
</div>
            <div class="span2">
                <?php 
echo TbHtml::btn(TbHtml::BUTTON_TYPE_LINK, Yii::t('user', 'Sign Up!'), array('color' => TbHtml::BUTTON_COLOR_SUCCESS, 'url' => '/user/registration'));
?>
            </div>
        </div>
    </div>
</div>
开发者ID:latik,项目名称:yii-user,代码行数:30,代码来源:login.php


注:本文中的TbHtml::btn方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。