signup.php 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <?php
  2. /**
  3. * Author: lf
  4. * Blog: https://blog.feehi.com
  5. * Email: job@feehi.com
  6. * Created at: 2017-03-15 21:16
  7. */
  8. /* @var $this yii\web\View */
  9. /* @var $form yii\bootstrap\ActiveForm */
  10. /* @var $model frontend\models\form\SignupForm */
  11. use yii\helpers\Html;
  12. use yii\bootstrap\ActiveForm;
  13. $this->title = Yii::t('frontend', 'Sign up') . '-' . Yii::$app->feehi->website_title;
  14. $this->params['breadcrumbs'][] = $this->title;
  15. ?>
  16. <div class="content-wrap">
  17. <div class="fill" style="width:500px; margin: 0 auto">
  18. <h1><?= Html::encode($this->title) ?></h1>
  19. <p><?= Yii::t('frontend', 'Please fill out the following fields to signup') ?>:</p>
  20. <div class="row">
  21. <ul class="formInput">
  22. <?php $form = ActiveForm::begin(['id' => 'form-signup']); ?>
  23. <?= $form->field($model, 'username', ['template' => "<li class='item'>{label}{input}\n{error}\n{hint}</li>", 'options' => ['class'=>'row'], 'labelOptions'=>['class'=>'col-sm-4'], 'inputOptions'=>['class'=>'col-sm-8']])->textInput(['autofocus' => true]) ?>
  24. <?= $form->field($model, 'email', ['template' => "<li class='item'>{label}{input}\n{error}\n{hint}</li>"])->textInput() ?>
  25. <?= $form->field($model, 'password', ['template' => "<li class='item'>{label}{input}\n{error}\n{hint}</li>"])->passwordInput() ?>
  26. <div class="submitButton">
  27. <?= Html::submitButton(Yii::t('frontend', 'SignUp'), ['class' => 'btn btn-primary', 'name' => 'signup-button']) ?>
  28. </div>
  29. <?php ActiveForm::end(); ?>
  30. </ul>
  31. </div>
  32. </div>
  33. </div>