From 9ceec74971f85022ad61699dc209d7044945b149 Mon Sep 17 00:00:00 2001 From: rub Date: Mon, 12 Feb 2007 23:21:23 +0000 Subject: When not template are selected for mail, PWG uses default template.. Sent multi-part message in MIME format. (With only one part for the moment). Improvement pwg_mail function. git-svn-id: http://piwigo.org/svn/trunk@1809 68402e56-0260-453c-a942-63ccdbb3a9ee --- admin/notification_by_mail.php | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) (limited to 'admin/notification_by_mail.php') diff --git a/admin/notification_by_mail.php b/admin/notification_by_mail.php index a000fdb4b..33e5f59dd 100644 --- a/admin/notification_by_mail.php +++ b/admin/notification_by_mail.php @@ -273,7 +273,7 @@ function do_action_send_mail_notification($action = 'list_to_send', $check_key_l } // set env nbm user - set_user_on_env_nbm($nbm_user['user_id'], $is_action_send); + set_user_on_env_nbm($nbm_user, $is_action_send); if ($is_action_send) { @@ -377,13 +377,20 @@ function do_action_send_mail_notification($action = 'list_to_send', $check_key_l 'byebye', array('SEND_AS_NAME' => $env_nbm['send_as_name']) ); - if (pwg_mail( + if (pwg_mail + ( format_email($nbm_user['username'], $nbm_user['mail_address']), - $env_nbm['send_as_mail_formated'], - $subject, - $env_nbm['mail_template']->parse('notification_by_mail', true), - $env_nbm['email_format'], $env_nbm['email_format'] - )) + array + ( + 'from' => $env_nbm['send_as_mail_formated'], + 'subject' => $subject, + 'email_format' => $env_nbm['email_format'], + 'content' => $env_nbm['mail_template']->parse('notification_by_mail', true), + 'content_format' => $env_nbm['email_format'], + 'template' => $nbm_user['template'], + 'theme' => $nbm_user['theme'] + ) + )) { inc_mail_sent_success($nbm_user); -- cgit v1.2.3