login.php 799 B

123456789101112131415161718192021222324
  1. <?php
  2. use yii\helpers\Html;
  3. use yii\widgets\ActiveForm;
  4. /**
  5. * @var yii\base\View $this
  6. * @var yii\widgets\ActiveForm $form
  7. * @var app\models\LoginForm $model
  8. */
  9. $this->title = 'Login';
  10. $this->params['breadcrumbs'][] = $this->title;
  11. ?>
  12. <h1><?php echo Html::encode($this->title); ?></h1>
  13. <p>Please fill out the following fields to login:</p>
  14. <?php $form = ActiveForm::begin(array('options' => array('class' => 'form-horizontal', 'id' => 'login-form'))); ?>
  15. <?php echo $form->field($model, 'username')->textInput(); ?>
  16. <?php echo $form->field($model, 'password')->passwordInput(); ?>
  17. <?php echo $form->field($model, 'rememberMe')->checkbox(); ?>
  18. <div class="form-actions">
  19. <?php echo Html::submitButton('Login', array('class' => 'btn btn-primary')); ?>
  20. </div>
  21. <?php ActiveForm::end(); ?>