Created
October 17, 2011 18:44
-
-
Save tjlytle/1293424 to your computer and use it in GitHub Desktop.
SendGrid Configuration for Zend Framework
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$config = array( | |
'username' => 'sendgridusername', | |
'password' => 'sendgridpassword', | |
'auth' => 'plain' | |
); | |
$transport = new Zend_Mail_Transport_Smtp('smtp.sendgrid.net', $config); | |
$mail = new Zend_Mail(); | |
$mail->setFrom('you@example.com', 'Your Name'); | |
$mail->setSubject('Email Test'); | |
$mail->setBodyHtml('<p>Test</p>'); | |
$mail->send($transport); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
$mail->addTo('you@example.com');