You are here

class MailhandlerCommandsExtendedHeaders in Mailhandler 6.2

Same name and namespace in other branches
  1. 7.2 modules/mailhandler_extended/plugins/mailhandler/commands/MailhandlerCommandsExtendedHeaders.class.php \MailhandlerCommandsExtendedHeaders

@file MailhandlerCommandsExtendedHeaders class.

Hierarchy

Expanded class hierarchy of MailhandlerCommandsExtendedHeaders

1 string reference to 'MailhandlerCommandsExtendedHeaders'
MailhandlerCommandsExtendedHeaders.inc in modules/mailhandler_extended/plugins/mailhandler/commands/MailhandlerCommandsExtendedHeaders.inc

File

modules/mailhandler_extended/plugins/mailhandler/commands/MailhandlerCommandsExtendedHeaders.class.php, line 7
MailhandlerCommandsExtendedHeaders class.

View source
class MailhandlerCommandsExtendedHeaders extends MailhandlerCommandsHeaders {

  /**
   * Build configuration form.
   */
  public function configForm(&$form, &$form_state, $config) {
    $form['extended_headers'] = array(
      '#type' => 'textarea',
      '#title' => t('Extended headers'),
      '#description' => t('Additional headers that can be mapped to Feeds processor targets.'),
      '#default_value' => $config['extended_headers'],
    );
  }
  function getMappingSources($config) {
    $sources = array();
    $extended_headers = explode("\n", $config['extended_headers']);
    foreach ($extended_headers as $header) {
      $header = trim($header);
      $sources[$header] = array(
        'name' => $header,
        'description' => $header . ' (extended header)',
      );
    }
    return $sources;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
MailhandlerCommands::$commands protected property
MailhandlerCommands::parse public function Parse commands from email body. 1
MailhandlerCommands::sourceForm public function Build source form. 1
MailhandlerCommandsExtendedHeaders::configForm public function Build configuration form. Overrides MailhandlerCommands::configForm
MailhandlerCommandsExtendedHeaders::getMappingSources function Return mapping sources in the same manner as a Feeds Parser. Overrides MailhandlerCommandsHeaders::getMappingSources
MailhandlerCommandsHeaders::process function Set known sources and parse additional sources from body. Overrides MailhandlerCommands::process