What to do? ')
Well aware that the documentation on the site is becoming outdated earlier, and the latest version of the framework was released quite recently, we are looking at the code.
And what do we see? Zend / Mail / Protocol / Smtp / Auth !!! HOORAY!
in accordance with the recommendation of the manual “To send an email via SMTP, you need to create and register a Zend_Mail_Transport_Smtp object before the send () method is called.All subsequent calls to Zend_Mail :: send () will use SMTP in the current script. ”
here you should pay attention to the second parameter Zend_Mail_Transport_Smtp in accordance with the code is an array /** * Config options for authentication * * @var array */ protected $_config;
Zend_Mail_Transport_Smtp cannot work with the configuration object, that is why it wants to convert it toArray ()
and where you need to send just a helmet mail
$mail = new Zend_Mail( 'windows-1251' ); $mail->setBodyText('This is the text of the mail.'); $mail->setFrom('somebody@example.com', 'Some Sender'); $mail->addTo('somebody_else@example.com', 'Some Recipient'); $mail->setSubject('TestSubject'); $mail->send();