Hi friends,
With FormIt how can i see attached files in incoming mail.
The codes in the modal-zv-tpl file are as follows;
<p>Телефон: <strong>[[+phone-zv]]</strong></p>
<p>E-mail: <strong>[[+message]]</strong></p>
Hi friends,
With FormIt how can i see attached files in incoming mail.
The codes in the modal-zv-tpl file are as follows;
<p>Телефон: <strong>[[+phone-zv]]</strong></p>
<p>E-mail: <strong>[[+message]]</strong></p>
With FormIt, if the form has enctype="multipart/form-data"
(and the property attachFilesToEmail
is true
) ,then the files are automatically added to the email as attachments.
<form ... enctype="multipart/form-data">
But you are using AjaxForm to send the form.
I don’t know if it works the same with AjaxForm. You have to test it.
Thank you, from which file should I do this?
In modal-zv-tpl
The codes are as follows;
<strong>[[+name-zv:empty=`Не заполнено`]]</strong> прислал(а) <strong>заявку на обратный звонок </strong> со страницы: <strong><a href="http://domen.ru/[[+link]]">[[+title]]</a></strong> <br />
Данные с формы:<br />
<p>Имя: <strong>[[+name-zv:empty=`Не заполнено`]]</strong></p>
<p>Телефон: <strong>[[+phone-zv]]</strong></p>
<p>Message: <strong>[[+message]]</strong></p>
In short, email information and attached files not have.
This is the template for the email message. Add the placeholder [[+email-zv]]
for the email information.
For the file attachments, change the <form>
tag in the chunk “tpl.AjaxForm”.
Thank you. E-mail okey. For form i use tpl.AjaxForm, but there are two section in Chunk.
For attachments in tpl.AjaxForm
<form method="post" class="ajax_form af_example">
{'Localizator' | snippet : [
'snippet' => 'pdoResources',
'parents'=>'0',
'resources'=>'157',
'depth'=>'0',
'tpl'=>'@INLINE [[+description]]',
]}
</form>
In tpl.AjaxForm.Example
<form action="" method="post" class="ajax_form af_example">
<div class="form-group">
<label class="control-label" for="af_name">[[%af_label_name]]</label>
<div class="controls">
<input type="text" id="af_name" name="name" value="[[+fi.name]]" placeholder="" class="form-control"/>
<span class="error_name">[[+fi.error.name]]</span>
</div>
</div>
<div class="form-group">
<label class="control-label" for="af_email">[[%af_label_email]]</label>
<div class="controls">
<input type="email" id="af_email" name="email" value="[[+fi.email]]" placeholder="" class="form-control"/>
<span class="error_email">[[+fi.error.email]]</span>
</div>
</div>
<div class="form-group">
<label class="control-label" for="af_message">[[%af_label_message]]</label>
<div class="controls">
<textarea id="af_message" name="message" class="form-control" rows="5">[[+fi.message]]</textarea>
<span class="error_message">[[+fi.error.message]]</span>
</div>
</div>
<div class="form-group">
<div class="controls">
<button type="reset" class="btn btn-default">[[%af_reset]]</button>
<button type="submit" class="btn btn-primary">[[%af_submit]]</button>
</div>
</div>
[[+fi.success:is=`1`:then=`
<div class="alert alert-success">[[+fi.successMessage]]</div>
`]]
[[+fi.validation_error:is=`1`:then=`
<div class="alert alert-danger">[[+fi.validation_error_message]]</div>
`]]
</form>
This is the form you use on your website.
This is only an example form (that gets added when you install the AjaxForm extra).
change the
<form>
tag in the chunk “tpl.AjaxForm”.
How i can do this part in tpl.AjaxForm ?
Open the chunk “tpl.AjaxForm” in the manager. Add the attribute enctype="multipart/form-data"
to the <form>
tag. Click “Save”.
Thank you. Solved with the code you provided.