You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 line
1.1KB

  1. <?php
  2. use yii\helpers\Html;
  3. use yii\bootstrap\ActiveForm;
  4. use yii\captcha\Captcha;
  5. $this->setTitle('Contact');
  6. ?>
  7. <div class="site-contact">
  8. <div class="row">
  9. <div class="col-lg-5">
  10. <?php $form = yii\bootstrap\ActiveForm::begin(['id' => 'contact-form', 'enableClientValidation' => false,]); ?>
  11. <?= $form->field($model, 'name') ?>
  12. <?= $form->field($model, 'email') ?>
  13. <?= $form->field($model, 'subject') ?>
  14. <?= $form->field($model, 'body')->textArea(['rows' => 6]) ?>
  15. <?php echo $form->field($model, 'verifyCode')->widget(yii\captcha\Captcha::className(), [
  16. 'template' => '<div class="row"><div class="col-lg-3">{image}</div><div class="col-lg-6">{input}</div></div>',
  17. ]); ?>
  18. <div class="form-group">
  19. <?= Html::submitButton('Envoyer', ['class' => 'btn btn-primary', 'name' => 'contact-button']) ?>
  20. </div>
  21. <?php ActiveForm::end(); ?>
  22. </div>
  23. </div>
  24. </div>