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


PHP CHtml::activePasswordField方法代码示例

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


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

示例1: renderInput

 public function renderInput($attr)
 {
     switch ($attr) {
         case 'password':
             echo CHtml::activePasswordField($this, $attr, $this->htmlOptions($attr));
             echo CHtml::label(Yii::t('app', 'Visible?'), 'visible', array('style' => 'display: inline'));
             echo CHtml::checkBox('visible', false, array('id' => 'password-visible', 'onchange' => 'js: x2.credManager.swapPasswordVisibility("#Credentials_auth_password")'));
             break;
         default:
             parent::renderInput($attr);
     }
 }
开发者ID:keyeMyria,项目名称:CRM,代码行数:12,代码来源:SendgridAccount.php

示例2: renderInput

 public function renderInput($attr)
 {
     switch ($attr) {
         case 'email':
             echo '<p class="fieldhelp-thin-small">' . Yii::t('app', '(example@gmail.com)') . '</p>';
             echo CHtml::activeTextField($this, $attr, $this->htmlOptions($attr));
             break;
         case 'password':
             echo CHtml::activePasswordField($this, $attr, $this->htmlOptions($attr));
             echo CHtml::label(Yii::t('app', 'Visible?'), 'visible', array('style' => 'display: inline'));
             echo CHtml::checkBox('visible', false, array('id' => 'password-visible', 'onchange' => 'js: x2.credManager.swapPasswordVisibility("#Credentials_auth_password")'));
             break;
         default:
             parent::renderInput($attr);
     }
 }
开发者ID:keyeMyria,项目名称:CRM,代码行数:16,代码来源:GMailAccount.php

示例3: run

 /**
  * Run this widget.
  * This method registers necessary CSS and JS files and renders the needed JS and HTML code.
  */
 public function run()
 {
     list($name, $id) = $this->resolveNameID();
     if (isset($this->htmlOptions['id'])) {
         $id = $this->htmlOptions['id'];
     } else {
         $this->htmlOptions['id'] = $id;
     }
     if (isset($this->htmlOptions['name'])) {
         $name = $this->htmlOptions['name'];
     }
     if ($this->hasModel()) {
         echo CHtml::activePasswordField($this->model, $this->attribute, $this->htmlOptions);
     } else {
         echo CHtml::passwordField($name, $this->value, $this->htmlOptions);
     }
     $this->registerClientScript();
     $this->registerClientScriptFiles();
 }
开发者ID:amlap,项目名称:Yii-Extensions,代码行数:23,代码来源:XPasswordStrength.php

示例4: run

 /**
  *### .run()
  *
  * Runs the widget.
  */
 public function run()
 {
     list($name, $id) = $this->resolveNameID();
     if ($this->hasModel()) {
         if ($this->form) {
             echo $this->form->passwordField($this->model, $this->attribute, $this->htmlOptions);
         } else {
             echo CHtml::activePasswordField($this->model, $this->attribute, $this->htmlOptions);
         }
     } else {
         echo CHtml::passwordField($name, $this->value, $this->htmlOptions);
     }
     $this->registerClientScript();
     $options = !empty($this->options) ? CJavaScript::encode($this->options) : '';
     ob_start();
     echo "jQuery('#{$id}').passField({$options})";
     foreach ($this->events as $event => $handler) {
         echo ".on('{$event}', " . CJavaScript::encode($handler) . ")";
     }
     Yii::app()->getClientScript()->registerScript(__CLASS__ . '#' . $this->getId(), ob_get_clean() . ';');
 }
开发者ID:AndressJose,项目名称:sistema-examenes,代码行数:26,代码来源:TbPassfield.php

示例5: switch

</div>
                    <div class="span5"><?php 
    switch ($item->options) {
        case "INT":
            echo CHtml::activeTextField($item, "[{$i}]key_value", array('title' => $item->helper_text, 'id' => $item->key_name, 'pattern' => '[0-9]+', 'title' => 'Only numbers are allowed'));
            break;
        case null:
        case "NULL":
        case "PINT":
            echo CHtml::activeTextField($item, "[{$i}]key_value", array('title' => $item->helper_text, 'id' => $item->key_name));
            break;
        case "EMAIL":
            echo CHtml::activeEmailField($item, "[{$i}]key_value", array('title' => $item->helper_text, 'id' => $item->key_name, 'pattern' => '^[a-zA-Z0-9!#$%&\'*+\\/=?^_`{|}~-]+(?:\\.[a-zA-Z0-9!#$%&\'*+\\/=?^_`{|}~-]+)*@(?:[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?\\.)+[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'));
            break;
        case "PASSWORD":
            echo CHtml::activePasswordField($item, "[{$i}]key_value", array('title' => $item->helper_text, 'id' => $item->key_name));
            break;
        case "BOOL":
            echo '<div class="onoff" id="' . $item->id . '" title="' . $item->helper_text . '"></div>';
            //Create On/Off
            echo CHtml::activeHiddenField($item, "[{$i}]key_value");
            break;
        default:
            echo CHtml::activeDropDownList($item, "[{$i}]key_value", Configuration::getAdminDropdownOptions($item->options), array('title' => $item->helper_text, 'id' => $item->key_name));
    }
    ?>
</div>
                    <div class="span1">
	                    <?php 
    if (!empty($item->helper_text)) {
        ?>
开发者ID:uiDeveloper116,项目名称:webstore,代码行数:31,代码来源:edit.php

示例6:

        <td><?php 
echo CHtml::activeTextField($form, 'username');
?>
</td>
        <td><?php 
echo CHtml::error($form, 'username');
?>
</td>
    </tr>
    <tr>
        <th><?php 
echo CHtml::activeLabel($form, 'password');
?>
</th>
        <td><?php 
echo CHtml::activePasswordField($form, 'password');
?>
</td>
        <td><?php 
echo CHtml::error($form, 'password');
?>
</td>
    </tr>
    <tr class="bottom">
        <td><?php 
echo CHtml::activeCheckBox($form, 'rememberMe');
?>
 <?php 
echo CHtml::activeLabel($form, 'rememberMe');
?>
</td>
开发者ID:anton-itscript,项目名称:WM-Web,代码行数:31,代码来源:login.php

示例7: array

?>


<?php 
echo CHtml::beginForm('', 'post', array('class' => 'form-group'));
?>
	<?php 
//echo Yum::requiredFieldNote();
?>
	<?php 
echo CHtml::errorSummary($form);
?>

	<?php 
if (!Yii::app()->user->isGuest) {
    echo CHtml::activePasswordField($form, 'currentPassword', $htmlOptions = array('class' => 'form-control', 'placeholder' => 'CURRENT PASSWORD'));
}
?>

<?php 
$this->renderPartial('user.views.user.passwordfields', array('form' => $form));
?>

	<?php 
echo CHtml::submitButton(Yum::t("Change Password"), array('class' => 'form-control'));
?>

<?php 
echo CHtml::endForm();
?>
开发者ID:usmansaleem10,项目名称:youthpowered,代码行数:30,代码来源:changepassword.php

示例8:

				<td><?php 
echo CHtml::activePasswordField($form, 'password_repeat');
?>
</td>
			</tr>
			<tr>
				<td><label for="AccountData_email">Email address</label></td>
				<td><?php 
echo CHtml::activeTextField($form, 'email');
?>
</td>
			</tr>
			<tr>
				<td><label for="AccountData_current_password">Current password</label></td>
				<td><?php 
echo CHtml::activePasswordField($form, 'current_password');
?>
</td>
			</tr>
			<tr>
				<td class="center" colspan="2"><input type="submit" class="button" name="yt0" value="Save changes"></td>
			</tr>
		</table>
		<?php 
echo CHtml::endForm();
?>
	</div>
</div>


<div class="note">
开发者ID:noiary,项目名称:Aion-Core-v4.7.5,代码行数:31,代码来源:settings.php

示例9: array

		<?php 
echo CHtml::activeTextField($model, 'username', array('placeholder' => 'User Name / Email', 'class' => 'inp-t'));
?>
		<?php 
echo CHtml::activeHiddenField($model, 'redirectUrl');
?>
		
	</div>
	<div class="pass-n">Password</div>
	<div class="rows">
    
		<?php 
//echo CHtml::activeLabelEx($model,'Password');
?>
		<?php 
echo CHtml::activePasswordField($model, 'password', array('placeholder' => 'Enter Password', 'class' => 'inp-t'));
?>
	</div>
	
		<div class="rows submit">
		<?php 
echo CHtml::submitButton(UserModule::t("Login"), array("class" => "log-but"));
?>
		
	</div>
	
	<div class="rows rememberMe">
		<?php 
echo CHtml::activeCheckBox($model, 'rememberMe');
?>
		<?php 
开发者ID:aftavwani,项目名称:Master,代码行数:31,代码来源:login.php

示例10: array

        <?php 
$attr = array('class' => 'form-control placeholder-no-fix', 'placeholder' => $attrName['mobile']);
?>
        <?php 
echo CHtml::activeTextField($form, 'mobile', $attr);
?>
    </div>

    <div class="form-group">
        <?php 
$attr = array('class' => 'form-control placeholder-no-fix', 'placeholder' => $attrName['password']);
?>
        <?php 
echo CHtml::activePasswordField($form, 'password', $attr);
?>
    </div>

    <div class="form-group">
        <?php 
$attr = array('class' => 'form-control placeholder-no-fix', 'placeholder' => $attrName['re_password']);
?>
        <?php 
echo CHtml::activePasswordField($form, 're_password', $attr);
?>
    </div>
    <input type="hidden" name="action" value="register" />
    <div class="form-actions">
        <button type="button" id="register-back-btn" class="btn btn-default">Quay lại</button>
        <button type="submit" id="register-submit-btn" class="btn btn-success uppercase pull-right">Đăng ký</button>
    </div>
</form>
开发者ID:haanhman,项目名称:rateapp,代码行数:31,代码来源:register.php

示例11:

	<p class="note"><?php 
echo UserModule::t('Fields with <span class="required">*</span> are required.');
?>
</p>
	<?php 
echo CHtml::errorSummary($form);
?>
	
	<div class="row">
	<?php 
echo CHtml::activeLabelEx($form, 'password');
?>
	<?php 
echo CHtml::activePasswordField($form, 'password');
?>
	<p class="hint">
	<?php 
echo UserModule::t("Minimal password length 4 symbols.");
?>
	</p>
	</div>
	
	<div class="row">
	<?php 
echo CHtml::activeLabelEx($form, 'verifyPassword');
?>
	<?php 
echo CHtml::activePasswordField($form, 'verifyPassword');
?>
	</div>
开发者ID:rainsongsky,项目名称:yincart,代码行数:30,代码来源:changepassword.php

示例12:

				<td><?php 
echo CHtml::activeLabel($form, 'password');
?>
</td>
				<td><?php 
echo CHtml::activePasswordField($form, 'password');
?>
</td>
			</tr>
			<tr>
				<td><?php 
echo CHtml::activeLabel($form, 'password_repeat');
?>
</td>
				<td><?php 
echo CHtml::activePasswordField($form, 'password_repeat');
?>
</td>
			</tr>
			<tr>
				<td><?php 
echo CHtml::activeLabel($form, 'email');
?>
</td>
				<td><?php 
echo CHtml::activeTextField($form, 'email');
?>
</td>
			</tr>
			<tr>
				<td><?php 
开发者ID:noiary,项目名称:Aion-Core-v4.7.5,代码行数:31,代码来源:register.php

示例13:

echo CHtml::activeLabel($user, 'username');
?>

<?php 
echo CHtml::activeTextField($user, 'username');
echo CHtml::error($user, 'username');
?>
</div>

<div class="simple">
<?php 
echo CHtml::activeLabel($user, 'password');
?>

<?php 
echo CHtml::activePasswordField($user, 'password');
echo CHtml::error($user, 'password');
?>
</div>

<div class="action">
<?php 
if ($this->enableRememberMe) {
    echo CHtml::activeCheckBox($user, 'rememberMe');
    ?>
 Remember me next time<br/>
<?php 
}
echo CHtml::submitButton('Login');
?>
</div>
开发者ID:sharmarakesh,项目名称:edusec-college-management-system,代码行数:31,代码来源:loginPortlet.php

示例14: array

echo CHtml::activeLabelEx($model, 'username');
?>
		<?php 
echo CHtml::activeTextField($model, 'username', array('size' => 20, 'maxlength' => 20));
?>
		<?php 
echo CHtml::error($model, 'username');
?>
	</div>

	<div class="row">
		<?php 
echo CHtml::activeLabelEx($model, 'password');
?>
		<?php 
echo CHtml::activePasswordField($model, 'password', array('size' => 60, 'maxlength' => 128));
?>
		<?php 
echo CHtml::error($model, 'password');
?>
	</div>

	<div class="row">
		<?php 
echo CHtml::activeLabelEx($model, 'email');
?>
		<?php 
echo CHtml::activeTextField($model, 'email', array('size' => 60, 'maxlength' => 128));
?>
		<?php 
echo CHtml::error($model, 'email');
开发者ID:reubsc,项目名称:sds,代码行数:31,代码来源:_form.php

示例15: array

						<?php 
    echo CHtml::activeTextField($form, 'username', array('class' => 'text', 'name' => 'username'));
    ?>
					</div>
				</div>
				<div class="item row2">
					<div class="left">
						<span class="icon">
							<?php 
    echo CHtml::activeLabel($form, 'password');
    ?>
						</span>
					</div>
					<div class="right">
						<?php 
    echo CHtml::activePasswordField($form, 'password', array('class' => 'text', 'value' => '', 'name' => 'password', 'autocomplete' => "off"));
    ?>
					</div>
				</div>
			</div>

			<div class="buttons">
				<a class="icon button primary" href="javascript:void(0);" onclick="$('form').submit()">
					<?php 
    echo Html::icon('login', 16, false, 'core.login');
    ?>
					<span><?php 
    echo Yii::t('core', 'login');
    ?>
</span>
				</a>
开发者ID:helloqingbing,项目名称:MySQL_Bench_Yii1.1.4,代码行数:31,代码来源:login.php


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