Reply To: Send a copy email to the submitter

#33252
Martin Taylor
Participant

Since posting this suggestion, I’ve noticed that there is an action hook ‘pta_member_contact_message_sent’ which fires after the message is sent. That could perhaps be used, but the problem is that it’s fired even if the wp_mail function fails.

What we need is for the do_action on this hook to be inside the success condition for wp_mail, or at least in a condition of its own, based on ($sent = true).