D
D
denism3002019-03-22 14:18:20
MODX
denism300, 2019-03-22 14:18:20

How to send emails in MODX Revo?

Made a feedback form using AjaxForm and FormIt.
Chunk tplModalCallback:

<div class="modal fade" id="modalCallback" tabindex="-1" role="dialog" aria-labelledby="modalCallbackTitle" aria-hidden="true">
    <div class="modal-dialog modal-dialog-centered" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title" id="modalCallbackTitle">Форма обратной связи</h5>
                <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                    <span aria-hidden="true">&times;</span>
                </button>
            </div>
            <div class="modal-body">
                
            </div>
        </div>
    </div>
</div>

contactForm chunk:
<form action="" method="post" class="ajax_form">
    <div class="form-group">
        <input type="text" name="name" required="" class="form-control" placeholder="Ваше имя*" value="">
        <span class="error error_name"></span>
    </div>
    <div class="form-group">
        <input type="email" name="email" required="" class="form-control" placeholder="Ваш email" value="">
        <span class="error error_name"></span>
    </div>
    <div class="form-group">
        <input type="text" class="form-control" id="phone" name="phone" required="" placeholder="Ваш телефон*" value="">
        <span class="error error_name"></span>
    </div>
    <div class="form-group">
        <textarea rows="4" name="message" required="" class="form-control word-count" data-maxlength="200" data-info="textarea-words-info" placeholder="Сообщение*"></textarea>
        <span class="error error_name"></span>
    </div>
    <div class="form-group form-check">
        <input type="checkbox" class="form-check-input" id="privacyCheck" required="">
        <span class="error error_name"></span>
        <label class="form-check-label" for="privacyCheck">Согласен на обработку персональных данных</label>
    </div>
    <p class="text-small">Ставя отметку, я даю свое согласие на обработку моих персональных данных в соответствии с законом №152-ФЗ «О персональных данных» от 27.07.2006 и принимаю условия <a href="" rel="nofollow" target="_blank">Пользовательского соглашения</a></p>
    <div class="text-center">
        <button type="submit" class="btn btn-landcad big-btn">Отправить</button>
    </div>
    
    
</form>

tplContactForm chunk
<p>Имя: </p>
<p>Email: </p>
<p>Телефон: </p>
<p>Сообщение: </p>

When you click on the send button, a notification about successful sending appears, but letters do not come to the mail.
At the same time, in the admin panel, in the FormIt section, they are saved.
In the configuration, the SMTP send setting is configured and enabled.
There are no errors in the logs.
What is the problem?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vladislav Lyskov, 2019-03-22
@denism300

&hooks=`email`should be
and it shouldn't be&hooks=`FormItSaveForm`

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question