mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 06:08:52 +00:00
To enclose the email address in <> is required for the RCPT TO Field, according to RFC 821. Since we do not use these <>'s within the TO Field while using the mail function (some servers are having problems with this) we need to re-add them within the smtpmail function.
git-svn-id: file:///svn/phpbb/branches/phpBB-2_0_0@4183 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
5a3f9d3bac
commit
305eb6c34a
1 changed files with 2 additions and 2 deletions
|
@ -153,10 +153,10 @@ function smtpmail($mail_to, $subject, $message, $headers = '')
|
||||||
$mail_to_address = trim($mail_to_address);
|
$mail_to_address = trim($mail_to_address);
|
||||||
if (preg_match('#[^ ]+\@[^ ]+#', $mail_to_address))
|
if (preg_match('#[^ ]+\@[^ ]+#', $mail_to_address))
|
||||||
{
|
{
|
||||||
fputs($socket, "RCPT TO: $mail_to_address\r\n");
|
fputs($socket, "RCPT TO: <$mail_to_address>\r\n");
|
||||||
server_parse($socket, "250", __LINE__);
|
server_parse($socket, "250", __LINE__);
|
||||||
}
|
}
|
||||||
$to_header .= (($to_header != '') ? ', ' : '') . "$mail_to_address";
|
$to_header .= (($to_header != '') ? ', ' : '') . "<$mail_to_address>";
|
||||||
}
|
}
|
||||||
|
|
||||||
// Ok now do the CC and BCC fields...
|
// Ok now do the CC and BCC fields...
|
||||||
|
|
Loading…
Add table
Reference in a new issue