You are here

function messaging_mail_messaging in Messaging 7

Same name and namespace in other branches
  1. 5 messaging_mail/messaging_mail.module \messaging_mail_messaging()
  2. 6.4 messaging_mail/messaging_mail.module \messaging_mail_messaging()
  3. 6 messaging_mail/messaging_mail.module \messaging_mail_messaging()
  4. 6.2 messaging_mail/messaging_mail.module \messaging_mail_messaging()
  5. 6.3 messaging_mail/messaging_mail.module \messaging_mail_messaging()

Implementation of hook_messaging().

Currently the only operation supported is 'send methods' that will retrieve and array with information fo the sending methods provided by this module.

Parameters

$op: Type of information to retrieve.

Return value

mixed Depending on $op

File

messaging_mail/messaging_mail.module, line 36
Simple mail using Drupal API. Messaging method plug-in.

Code

function messaging_mail_messaging($op, $type = NULL) {
  switch ($op) {
    case 'send methods':
      $info['mail'] = array(
        'title' => t('Drupal mail'),
        'class' => 'Messaging_Mail_Method',
        'name' => t('Mail'),
        'description' => t('Get messages as plain text e-mail.'),
      );
      return $info;
    case 'address types':

      // Get some built in address types.
      $types['mail'] = array(
        // Name for display.
        'name' => t('E-mail address'),
        'class' => 'Messaging_Mail_Address',
      );
      return $types;
  }
}