diff options
| author | Paul S. Owen <psotfx@users.sourceforge.net> | 2001-10-05 14:13:58 +0000 |
|---|---|---|
| committer | Paul S. Owen <psotfx@users.sourceforge.net> | 2001-10-05 14:13:58 +0000 |
| commit | d2f2d1092903aa09e5695857613c5d61e55f8d4f (patch) | |
| tree | e91025861371f77dd7936302c0e087464fc3b2a8 /phpBB/posting.php | |
| parent | 5692f347e501deb53e03b474adb10c919e5e7966 (diff) | |
| download | forums-d2f2d1092903aa09e5695857613c5d61e55f8d4f.tar forums-d2f2d1092903aa09e5695857613c5d61e55f8d4f.tar.gz forums-d2f2d1092903aa09e5695857613c5d61e55f8d4f.tar.bz2 forums-d2f2d1092903aa09e5695857613c5d61e55f8d4f.tar.xz forums-d2f2d1092903aa09e5695857613c5d61e55f8d4f.zip | |
Moved emailer instantiation out of loop, was causing failures during topic reply notifications
git-svn-id: file:///svn/phpbb/trunk@1128 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/posting.php')
| -rw-r--r-- | phpBB/posting.php | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/phpBB/posting.php b/phpBB/posting.php index a995bd7b25..ddc3154b35 100644 --- a/phpBB/posting.php +++ b/phpBB/posting.php @@ -747,22 +747,21 @@ if( ( $submit || $confirm ) && !$error ) $email_set = $db->sql_fetchrowset($result); $update_watched_sql = ""; + include($phpbb_root_path . 'includes/emailer.'.$phpEx); + $emailer = new emailer($board_config['smtp_delivery']); + + $email_headers = "From: " . $board_config['board_email'] . "\nReturn-Path: " . $board_config['board_email'] . "\r\n"; + $path = (dirname($HTTP_SERVER_VARS['REQUEST_URI']) == "/") ? "" : dirname($HTTP_SERVER_VARS['REQUEST_URI']); + for($i = 0; $i < count($email_set); $i++) { if( $email_set[$i]['user_email'] != "") { - include($phpbb_root_path . 'includes/emailer.'.$phpEx); - $emailer = new emailer($board_config['smtp_delivery']); - - $email_headers = "From: " . $board_config['board_email'] . "\nReturn-Path: " . $board_config['board_email'] . "\r\n"; - $emailer->use_template("topic_notify"); $emailer->email_address($email_set[$i]['user_email']); $emailer->set_subject($lang['Topic_reply_notification']); $emailer->extra_headers($email_headers); - $path = (dirname($HTTP_SERVER_VARS['REQUEST_URI']) == "/") ? "" : dirname($HTTP_SERVER_VARS['REQUEST_URI']); - $emailer->assign_vars(array( "EMAIL_SIG" => str_replace("<br />", "\n", "-- \n" . $board_config['board_email_sig']), "USERNAME" => $email_set[$i]['username'], |
