[Phpfreechat-svn] SF.net SVN: phpfreechat: [1055] trunk/src/pfci18n.class.php
Status: Beta
Brought to you by:
kerphi
From: <ke...@us...> - 2007-07-20 18:40:26
|
Revision: 1055 http://svn.sourceforge.net/phpfreechat/?rev=1055&view=rev Author: kerphi Date: 2007-07-20 11:40:26 -0700 (Fri, 20 Jul 2007) Log Message: ----------- Fix a possible warning Modified Paths: -------------- trunk/src/pfci18n.class.php Modified: trunk/src/pfci18n.class.php =================================================================== --- trunk/src/pfci18n.class.php 2007-07-20 13:46:58 UTC (rev 1054) +++ trunk/src/pfci18n.class.php 2007-07-20 18:40:26 UTC (rev 1055) @@ -25,7 +25,7 @@ function _pfc() { $args = func_get_args(); - $serverid = $GLOBALS['serverid']; // serverid is used to avoid conflicts with external code using same 'i18n' key + $serverid = isset($GLOBALS['serverid']) ? $GLOBALS['serverid'] : 0; // serverid is used to avoid conflicts with external code using same 'i18n' key $args[0] = isset($GLOBALS[$serverid]["i18n"][$args[0]]) && $GLOBALS[$serverid]["i18n"][$args[0]] != "" ? ($GLOBALS["output_encoding"] == "UTF-8" ? $GLOBALS[$serverid]["i18n"][$args[0]] : @@ -40,7 +40,7 @@ function _pfc2() { $args = func_get_args(); - $serverid = $GLOBALS['serverid']; // serverid is used to avoid conflicts with external code using same 'i18n' key + $serverid = isset($GLOBALS['serverid']) ? $GLOBALS['serverid'] : 0; // serverid is used to avoid conflicts with external code using same 'i18n' key $args[0] = isset($GLOBALS[$serverid]["i18n"][$args[0]]) && $GLOBALS[$serverid]["i18n"][$args[0]] != "" ? ($GLOBALS["output_encoding"] == "UTF-8" ? $GLOBALS[$serverid]["i18n"][$args[0]] : @@ -64,7 +64,7 @@ else require_once(dirname(__FILE__)."/../i18n/".$language."/main.php"); - $serverid = $GLOBALS['serverid']; // serverid is used to avoid conflicts with external code using same 'i18n' key + $serverid = isset($GLOBALS['serverid']) ? $GLOBALS['serverid'] : 0; // serverid is used to avoid conflicts with external code using same 'i18n' key $GLOBALS[$serverid]['i18n'] = $GLOBALS['i18n']; // do not pass by reference because $GLOBALS['i18n'] is maybe used by unknown external code $GLOBALS["output_encoding"] = "UTF-8"; // by default client/server communication is utf8 encoded @@ -192,4 +192,4 @@ } } -?> \ No newline at end of file +?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |