Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Sending email via SMTP on zend framework

$config = array('auth' => 'login',
                'username' => '****@gmail.com',
                'password' => '****',
                'port' => '25',
                'ssl' => 'tls');


$transport = new Zend_Mail_Transport_Smtp('smtp.googlemail.com', $config);

what should i do after that, where can i put the body and the recipient address.

like image 280
haider Avatar asked Sep 06 '25 16:09

haider


1 Answers

Its described in the manual of Zendframework

Zend_Mail::setDefaultTransport($transport);

Then somewhere else instanciate Zend_Mail, write your mail and send it.

like image 115
KingCrunch Avatar answered Sep 08 '25 12:09

KingCrunch