You are here

function simple_mail_mail in Simple Mail 7

Same name and namespace in other branches
  1. 8 simple_mail.module \simple_mail_mail()
  2. 2.0.x simple_mail.module \simple_mail_mail()

Implements hook_mail().

Send HTML emails.

@todo - Also add plain text alternative.

File

./simple_mail.module, line 37
Simple Mail module.

Code

function simple_mail_mail($key, &$message, $params) {
  switch ($key) {
    case 'simple_mail':
      $message['headers']['Content-Type'] = 'text/html; charset=UTF-8;';
      $message['subject'] = $params['subject'];
      $message['body'][] = $params['body'];
      break;
  }
}