Ignore:
Timestamp:
10/23/07 15:01:25 (5 years ago)
Author:
root
Message:

Removed the main.advertising.tpl panel, moved it to the module template directory

File:
1 edited

Legend:

Unmodified
Added
Removed
  • modules/common/advertising/php-files/modules/advertising/advertising.php

    r999 r1000  
    1010| the included gpl.txt file or visit http://gnu.org  | 
    1111+----------------------------------------------------*/ 
    12 require_once dirname(__FILE__)."/includes/core_functions.php"; 
     12require_once dirname(__FILE__)."/../../includes/core_functions.php"; 
    1313require_once PATH_ROOT."/includes/theme_functions.php"; 
    1414 
     
    1616$variables = array(); 
    1717 
    18 // include the locale for this module 
    19 include PATH_LOCALE.LOCALESET."admin/adverts.php"; 
     18// load the locale for this panel 
     19if (file_exists(PATH_MODULES."advertising/locale/".$settings['locale'].".php")) { 
     20        $locale_file = PATH_MODULES."advertising/locale/".$settings['locale'].".php"; 
     21} else { 
     22        $locale_file = PATH_MODULES."advertising/locale/English.php"; 
     23} 
     24include $locale_file; 
    2025 
    2126// include the sendmail module 
     
    258263 
    259264// define the body panel variables 
    260 $template_panels[] = array('type' => 'body', 'name' => 'advertising', 'template' => 'main.advertising.tpl', 'locale' => PATH_LOCALE.LOCALESET."admin/adverts.php"); 
    261 $template_variables['advertising'] = $variables; 
     265$template_panels[] = array('type' => 'body', 'name' => 'modules.advertising', 'template' => 'modules.advertising.tpl', 'locale' => $locale_file); 
     266$template_variables['modules.advertising'] = $variables; 
    262267 
    263268// Call the theme code to generate the output for this webpage 
Note: See TracChangeset for help on using the changeset viewer.