| Status | Draft |
|---|---|
| Todo | fill in connect, fuller description, expand configuration |
An Email helper to work with the Swift email library.
The swiftmailer configuration for this helper is found in config/email.php
Inside the config/email.php file you can select the driver type which are native, sendmail, smtp
Example: using smtp
$config['driver'] = 'smtp'; $config['options'] = array('hostname'=>'yourhostname', 'username'=>'yourusername', 'password'=>'yourpassword', 'port'=>'25');
'send' sends an e-mail using the specified information. The parameters are:
Example:
$to = 'to@example.com'; // Address can also be array('to@example.com', 'Name') $from = 'from@example.com'; $subject = 'This is an example subject'; $message = 'This is an <strong>example</strong> message'; email::send($to, $from, $subject, $message, TRUE);