Changeset 1284 in ExiteCMS


Ignore:
Timestamp:
02/17/08 10:39:11 (4 years ago)
Author:
hverton
Message:

automatically detect and load the module locale for a module panel

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/theme_functions.php

    r1263 r1284  
    370370                            $_panel['panel_code'] = PATH_MODULES.$p_data['panel_filename']; 
    371371                        } 
     372                        // check if there is a locale for this panel 
     373                        $_panel['locale'] = 'modules.'.dirname($p_data['panel_filename']); 
     374                        $result = dbquery("SELECT * FROM ".$db_prefix."locales WHERE locales_name = '".$_panel['locale']."' LIMIT 1"); 
     375                        if (dbrows($result)==0) unset($_panel['locale']); 
    372376                        break; 
    373377                    case "dynamic": 
Note: See TracChangeset for help on using the changeset viewer.