diff options
author | alecpl <alec@alec.pl> | 2009-07-06 09:13:10 +0000 |
---|---|---|
committer | alecpl <alec@alec.pl> | 2009-07-06 09:13:10 +0000 |
commit | 2818f8e9ed5e8853e33636ac8efe09e2a4161618 (patch) | |
tree | 1bd0c3a4534704922c5ad80647a4334c28cc2082 /program/steps/mail/sendmail.inc | |
parent | 2f2bb4020b5d3a79a65177d54fe1b5ade1efb69d (diff) |
- Show SMTP errors in browser (#1485927)
Diffstat (limited to 'program/steps/mail/sendmail.inc')
-rw-r--r-- | program/steps/mail/sendmail.inc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/program/steps/mail/sendmail.inc b/program/steps/mail/sendmail.inc index d550a422d..c5a2ea7c3 100644 --- a/program/steps/mail/sendmail.inc +++ b/program/steps/mail/sendmail.inc @@ -441,12 +441,15 @@ if (!$savedraft) $OUTPUT->send('iframe'); } - $sent = rcmail_deliver_message($MAIL_MIME, $from, $mailto); + $sent = rcmail_deliver_message($MAIL_MIME, $from, $mailto, $smtp_error); // return to compose page if sending failed if (!$sent) { - $OUTPUT->show_message("sendingfailed", 'error'); + if ($smtp_error) + $OUTPUT->show_message($smtp_error['label'], 'error', $smtp_error['vars']); + else + $OUTPUT->show_message('sendingfailed', 'error'); $OUTPUT->send('iframe'); } |