Changeset 266 for trunk/phpgwapi/inc/functions.inc.php
- Timestamp:
- 04/18/08 11:39:51 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/phpgwapi/inc/functions.inc.php
r2 r266 53 53 $vars = array($m1,$m2,$m3,$m4,$m5,$m6,$m7,$m8,$m9,$m10); 54 54 } 55 // Get the translation from Lang File, if the database is down. 56 if(!$GLOBALS['phpgw']->translation){ 57 $fn = PHPGW_SERVER_ROOT.'/phpgwapi/setup/phpgw_'.$GLOBALS['_SERVER']['HTTP_ACCEPT_LANGUAGE'].'.lang'; 58 if (file_exists($fn)){ 59 $fp = fopen($fn,'r'); 60 while ($data = fgets($fp,16000)){ 61 list($message_id,$app_name,$null,$content) = explode("\t",substr($data,0,-1)); 62 $GLOBALS['phpgw_info']['phpgwapi']['lang'][$message_id] = $content; 63 } 64 fclose($fp); 65 } 66 $return = str_replace('%1',$vars[0],$GLOBALS['phpgw_info']['phpgwapi']['lang'][$key]); 67 return $return; 68 } 55 69 $value = $GLOBALS['phpgw']->translation->translate("$key",$vars); 56 70 return $value; … … 163 177 /*echo '<center><b>Fatal Error:</b> It appears that you have not created the database tables for ' 164 178 .'eGroupWare. Click <a href="' . $setup_dir . '">here</a> to run setup.</center>';*/ 165 echo '<center><b>ExpressoLivre indisponível no momento. Códgio 001<br>' . 166 'Tente mais tarde.</b></center>'; 179 echo '<center><b>'.lang("ExpressoLivre is unavailable at this moment. Code %1<br>Please, try later.","001").'</b></center>'; 167 180 /* END - CELEPAR - jakjr - 05/06/2006 */ 168 181 exit;
Note: See TracChangeset
for help on using the changeset viewer.