[phpcvsview-cvs-updates] phpcvsview utils.php,1.8,1.9
Status: Pre-Alpha
Brought to you by:
bcheesem
From: Brian C. <bch...@us...> - 2005-02-04 11:03:25
|
Update of /cvsroot/phpcvsview/phpcvsview In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25348 Modified Files: utils.php Log Message: Fixed PHP Notice under IIS where $_ENVIRON['LANGUAGE'] is not available. Index: utils.php =================================================================== RCS file: /cvsroot/phpcvsview/phpcvsview/utils.php,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** utils.php 4 Feb 2005 09:47:54 -0000 1.8 --- utils.php 4 Feb 2005 11:03:13 -0000 1.9 *************** *** 148,156 **** global $env, $config, $_ENVIRON; // en_AU:en_GB:en ! $PreferredLangs = explode(":", $_ENVIRON['LANGUAGE']); ! foreach ($PreferredLangs as $Lang) { ! $FileToCheck = $env['language_path']."$Lang.php"; ! if (file_exists($FileToCheck)) { ! return $Lang; } } --- 148,158 ---- global $env, $config, $_ENVIRON; // en_AU:en_GB:en ! if (isset($_ENVIRON['LANGUAGE'])) { ! $PreferredLangs = explode(":", $_ENVIRON['LANGUAGE']); ! foreach ($PreferredLangs as $Lang) { ! $FileToCheck = $env['language_path']."$Lang.php"; ! if (file_exists($FileToCheck)) { ! return $Lang; ! } } } |