From: Reini U. <ru...@us...> - 2005-02-08 13:27:09
|
Update of /cvsroot/phpwiki/phpwiki/lib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8121 Modified Files: config.php Log Message: improve the locale splitter Index: config.php =================================================================== RCS file: /cvsroot/phpwiki/phpwiki/lib/config.php,v retrieving revision 1.132 retrieving revision 1.133 diff -u -2 -b -p -d -r1.132 -r1.133 --- config.php 7 Feb 2005 15:39:02 -0000 1.132 +++ config.php 8 Feb 2005 13:26:59 -0000 1.133 @@ -250,10 +250,12 @@ function guessing_setlocale ($category, if ($res = setlocale($category, $try)) return $res; - foreach (array('@', ".", '_') as $sep) { - list ($try) = split($sep, $try); - if ($res = setlocale($category, $try)) + foreach (array(".", '@', '_') as $sep) { + if ($i = strpos($try, $sep)) { + $try = substr($try, 0, $i); + if (($res = setlocale($category, $try))) return $res; } } + } return false; // A standard locale name is typically of the form @@ -527,4 +529,7 @@ function getUploadDataPath() { // $Log$ +// Revision 1.133 2005/02/08 13:26:59 rurban +// improve the locale splitter +// // Revision 1.132 2005/02/07 15:39:02 rurban // another locale fix |