Answer the question
In order to leave comments, you need to log in
[[+content_image]]
How to display values in Modx?
there is a form
[[!FormIt?
&hooks=`email, redirect,FormItSaveForm`
&emailTpl=`zayavkaEmailTpl1`
&emailTo=`[email protected]`
&emailFrom=`[email protected]`
&emailSubject=`Новая заявка на [[pdoField? &id=`0` &field=`pagetitle`]] на сайте na-goru!`
&redirectTo=`134`
&validate=`rule:required`
&formName=`Заявка `
&formFields=`field`
&fieldNames=`date_start==Дата начала,date_end==Дата окончания,about==Доп текст`
]]
<form name="contactForm" id="contact-form" class="contact-form form form-equival" method="post" action="">
<div class="row-fluid">
<label>Ваше ФИО (полностью)</label>
<input class="input" required type="text" name='fields[0][name]'>
</div>
<div class="row-fluid">
<label>Ваш E-mail</label>
<input class="input" required type="email" name='fields[0][email]'>
</div>
<div class="row-fluid" >
<label>Ваш телефон (в международном формате)</label>
<input class="input" required type="text" name="fields[0][phone]">
</div>
</form>
{foreach $fields as $field index=$i}
{$field[phone]}
{$field[email]}
{/foreach}
Answer the question
In order to leave comments, you need to log in
In the input form, change to:
<input class="input" required type="text" name="name">
<input class="input" required type="email" name="email">
<input class="input" required type="text" name="phone">
<p><strong>Имя</strong>: {$name}</p>
<p><strong>Почта</strong>: {$email}</p>
<p><strong>Телефон</strong>: {$phone}</p>
<p><strong>Имя</strong>: [[+name]]</p>
<p><strong>Почта</strong>: [[+email]]</p>
<p><strong>Телефон</strong>: [[+phone]]</p>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question