You are here

function views_send_mail in Views Send 8

Same name and namespace in other branches
  1. 6 views_send.module \views_send_mail()
  2. 7 views_send.module \views_send_mail()

Implements hook_mail().

File

./views_send.module, line 642
The Views Send module.

Code

function views_send_mail($key, &$message, $params) {

  // This is a simple message send. User inputs the content directly.
  if ($key == 'direct') {

    // Set the subject.
    $message['subject'] = $params['subject'];

    // Set the body.
    $message['body'][] = $params['body'];

    // Add additional headers.
    $message['headers'] += $params['headers'];
  }
  elseif ($key == 'node') {

    // Translations, theming, etc...
  }
}