You are here

function MimeMailPHPMailer::SetLanguage in PHPMailer 5

Same name and namespace in other branches
  1. 6 includes/mimemail.inc \MimeMailPHPMailer::SetLanguage()

Sets the language for all class error messages.

Overrides PHPMailer::SetLanguage

File

includes/mimemail.inc, line 45

Class

MimeMailPHPMailer

Code

function SetLanguage($lang_type, $lang_path = null) {
  $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: ');
  $this->language = $PHPMAILER_LANG;
  return true;
}