Ignore:
Timestamp:
Oct 9, 2007, 1:46:09 AM (17 years ago)
Author:
rvelices
Message:
  • some code refactoring before upgrade to utf (only cosmetic at this point...)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/functions_mail.inc.php

    r2122 r2126  
    4949
    5050  global $lang_info;
    51   return '=?'.$lang_info['charset'].'?Q?'.$str.'?=';
     51  return '=?'.get_pwg_charset().'?Q?'.$str.'?=';
    5252}
    5353
     
    227227
    228228      // language files
    229       include(get_language_filepath('common.lang.php', '', $language));
     229      load_language('common.lang', '', $language);
    230230      // No test admin because script is checked admin (user selected no)
    231231      // Translations are in admin file too
    232       include(get_language_filepath('admin.lang.php', '', $language));
     232      load_language('admin.lang', '', $language);
    233233      trigger_action('loading_lang');
    234       @include(get_language_filepath('local.lang.php', '', $language));
     234      load_language('local.lang', '', $language);
    235235
    236236      $switch_lang[$language]['lang_info'] = $lang_info;
     
    589589  $content = '';
    590590
    591   if (!isset($conf_mail[$args['email_format']][$lang_info['charset']][$args['template']][$args['theme']]))
     591  if (!isset($conf_mail[$args['email_format']][get_pwg_charset()][$args['template']][$args['theme']]))
    592592  {
    593593    if (!isset($mail_template))
     
    604604        'BOUNDARY_KEY' => $conf_mail['boundary_key'],
    605605        'CONTENT_TYPE' => $args['email_format'],
    606         'CONTENT_ENCODING' => $lang_info['charset'],
     606        'CONTENT_ENCODING' => get_pwg_charset(),
    607607        'LANG' => $lang_info['code'],
    608608        'DIR' => $lang_info['direction'],
     
    651651    // what are displayed on the header of each mail ?
    652652    $conf_mail[$args['email_format']]
    653       [$lang_info['charset']]
     653      [get_pwg_charset()]
    654654      [$args['template']][$args['theme']]['header'] =
    655655        $mail_template->parse('mail_header', true);
     
    657657    // what are displayed on the footer of each mail ?
    658658    $conf_mail[$args['email_format']]
    659       [$lang_info['charset']]
     659      [get_pwg_charset()]
    660660      [$args['template']][$args['theme']]['footer'] =
    661661        $mail_template->parse('mail_footer', true);
     
    664664  // Header
    665665  $content.= $conf_mail[$args['email_format']]
    666               [$lang_info['charset']]
     666              [get_pwg_charset()]
    667667              [$args['template']][$args['theme']]['header'];
    668668
     
    684684  // Footer
    685685  $content.= $conf_mail[$args['email_format']]
    686               [$lang_info['charset']]
     686              [get_pwg_charset()]
    687687              [$args['template']][$args['theme']]['footer'];
    688688
Note: See TracChangeset for help on using the changeset viewer.