You are here

function _smtp_initialize_language in SMTP Authentication Support 5

PHPMailer language settings. English Version Pulled from phpmailer.lang-en.php and t() functions added for drupal translations. This function is called in the line "$this->language = _smtp_initialize_language();" around line 794.

1 call to _smtp_initialize_language()
PHPMailer::SetLanguage in ./smtp.module
Sets the language for all class error messages. Returns false if it cannot load the language file. The default language type is English.

File

./smtp.module, line 413
Enables drupal to send email directly to an SMTP server using authentication. Uses the PHPMailer class by Brent R. Matzelle.

Code

function _smtp_initialize_language() {
  $PHPMAILER_LANG = array();
  $PHPMAILER_LANG["provide_address"] = t('You must provide at least one recipient email address.');
  $PHPMAILER_LANG["mailer_not_supported"] = ' ' . t('mailer is not supported.');
  $PHPMAILER_LANG["execute"] = t('Could not execute:') . ' ';
  $PHPMAILER_LANG["instantiate"] = t('Could not instantiate mail function.');
  $PHPMAILER_LANG["authenticate"] = t('SMTP Error: Could not authenticate.');
  $PHPMAILER_LANG["from_failed"] = t('The following From address failed:') . ' ';
  $PHPMAILER_LANG["recipients_failed"] = t('SMTP Error: The following recipients failed:') . ' ';
  $PHPMAILER_LANG["data_not_accepted"] = t('SMTP Error: Data not accepted.');
  $PHPMAILER_LANG["connect_host"] = t('SMTP Error: Could not connect to SMTP host.');
  $PHPMAILER_LANG["file_access"] = t('Could not access file:') . ' ';
  $PHPMAILER_LANG["file_open"] = t('File Error: Could not open file:') . ' ';
  $PHPMAILER_LANG["encoding"] = t('Unknown encoding:') . ' ';
  return $PHPMAILER_LANG;
}