writesdown/app-cms

View on GitHub
backend/views/user/_reset-password.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php
/**
 * @link http://www.writesdown.com/
 * @author Agiel K. Saputra <13nightevil@gmail.com>
 * @copyright Copyright (c) 2015 WritesDown
 * @license http://www.writesdown.com/license/
 */

use yii\helpers\Html;
use yii\widgets\ActiveForm;

/* @var $this yii\web\View */
/* @var $model common\models\User */
/* @var $form yii\widgets\ActiveForm */
?>
<div class="user-form">
    <?php $form = ActiveForm::begin(['id' => 'user-reset-password-form']) ?>

    <?= $form->field($model, 'password_old')->passwordInput([
        'maxlength' => 255,
        'placeholder' => $model->getAttributeLabel('password_old'),
    ]) ?>

    <?= $form->field($model, 'password')->passwordInput([
        'maxlength' => 255,
        'placeholder' => $model->getAttributeLabel('password'),
    ]) ?>

    <?= $form->field($model, 'password_repeat')->passwordInput([
        'maxlength' => 255,
        'placeholder' => $model->getAttributeLabel('password_repeat'),
    ]) ?>

    <div class="form-group">
        <?= Html::submitButton(Yii::t('writesdown', 'Save my new password'), ['class' => 'btn-flat btn btn-primary']) ?>

    </div>
    <?php ActiveForm::end() ?>

</div>