mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
Fixed the formation to send the emails to server, following the RFC 821.
This commit is contained in:
parent
b29c31709e
commit
85645496ea
1 changed files with 2 additions and 2 deletions
|
@ -140,14 +140,14 @@ class SmtpTransport extends AbstractTransport {
|
|||
*/
|
||||
protected function _sendRcpt() {
|
||||
$from = $this->_cakeEmail->getFrom();
|
||||
$this->_smtpSend('MAIL FROM: ' . key($from));
|
||||
$this->_smtpSend('MAIL FROM:<' . key($from) . '>');
|
||||
|
||||
$to = $this->_cakeEmail->getTo();
|
||||
$cc = $this->_cakeEmail->getCc();
|
||||
$bcc = $this->_cakeEmail->getBcc();
|
||||
$emails = array_merge(array_keys($to), array_keys($cc), array_keys($bcc));
|
||||
foreach ($emails as $email) {
|
||||
$this->_smtpSend('RCPT TO: ' . $email);
|
||||
$this->_smtpSend('RCPT TO:<' . $email . '>');
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue