source: trunk/expressoCalendar/inc/load_lang.php @ 632

Revision 632, 736 bytes checked in by niltonneto, 15 years ago (diff)

Modulo calendar_new renomeado para expressoCalendar

  • Property svn:executable set to *
Line 
1<?
2// Load the lang of the module.
3        if(!$_SESSION['phpgw_info']['calendar']['lang'])
4        {
5                $array_keys = array();
6                $fn = '../setup/phpgw_'.$_SESSION['calendar']['user']['preferences']['common']['lang'].'.lang';                 
7                if (file_exists($fn)){
8                        $fp = fopen($fn,'r');
9                        while ($data = fgets($fp,16000))        {
10                                list($message_id,$app_name,$null,$content) = explode("\t",substr($data,0,-1));                 
11                                $_SESSION['phpgw_info']['calendar']['lang'][$message_id] =  $content;
12                        }
13                        fclose($fp);
14                }
15        }
16        $script  = "array_lang = new Array();";
17        foreach($_SESSION['phpgw_info']['calendar']['lang'] as $key => $value)
18                $script .= "array_lang['".str_replace("'","\'",strtolower($key))."'] = '".str_replace("'","\'",$value)."';\n";
19        echo $script;
20
21?>
Note: See TracBrowser for help on using the repository browser.