D
D
DMax9212018-07-16 19:46:00
MODX
DMax921, 2018-07-16 19:46:00

Error in Modx feedback form how to fix?

Hello, friends!
Asked to correct the feedback form, does not send letters.
The error "The form contains errors" is raised and the form with the Mail is highlighted in red, such as the mail address is not correct or missing ...
The form is displayed with two additions FormIt and AjaxForm
Here is the standard code that walks on the net.
Create Chunk tpl.AjaxForm
with code

<form action="" method="post" class="ajax_form af_example form-horizontal">
  <div class="control-group">
    <label class="control-label" for="af_name">Имя*</label>
    <div class="controls">
      <input type="text" id="af_name" name="name" value="" placeholder="Введите имя">
      <span class="error_name"></span>
    </div>
  </div>
  <div class="control-group">
    <label class="control-label" for="af_email">E-mail*</label>
    <div class="controls">
      <input type="email" id="af_email" name="email" value="" placeholder="Введите email">
      <span class="error_email"></span>
    </div>
  </div>
  <div class="control-group">
    <label class="control-label" for="af_phone">Телефон</label>
    <div class="controls">
       <input type="text" id="af_phone" name="phone" value="" placeholder="Введите номер телефона">
      <span class="error_phone"></span>
    </div>
  </div>
  <div class="control-group">
    <label class="control-label" for="af_message">Сообщение*</label>
    <div class="controls">
      <textarea id="af_message" name="message" rows="5"></textarea>
      <span class="error_message"></span>
    </div>
  </div>
  <div class="control-group">
    <div class="controls">
      <button type="reset" class="btn btn-default">Очистить</button>
      <button type="submit" class="btn btn-primary">Отправить</button>
    </div>
  </div>
</form>

Calling an AjaxForm snippet on the contact page

Chunk tpl.email with the template of the letter itself
<h3>Сообщение</h3>
<p>От кого: </p>
<p>E-mail: </p>
<p>Телефон: </p>
<p>Сообщение: </p>

And it does not work, I tried a bunch of similar ones, the result is the same.
Please tell me how to solve the problem?
Thank you!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Golyagin, 2018-07-29
@webrevenue

Take the code from my article Building MODX Contact Forms with Formit... - 100% Working

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question