From 235d87a44b1d98bd4556753858289918299f8b1d Mon Sep 17 00:00:00 2001 From: dairiki Date: Thu, 8 Nov 2001 23:15:43 +0000 Subject: [PATCH] Fix SF bug #420986: Fix PHP "Warning: Passing locale category name as string is deprecated...." git-svn-id: svn://svn.code.sf.net/p/phpwiki/code/branches/release-1_2-branch@625 96ab9672-09ca-45d6-a79d-3d69d39ca109 --- lib/config.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/config.php b/lib/config.php index 6f7a63764..76ea2b309 100644 --- a/lib/config.php +++ b/lib/config.php @@ -10,7 +10,7 @@ if (!function_exists('rcs_id')) { function rcs_id($id) { echo "\n"; }; } - rcs_id('$Id: config.php,v 1.24.2.5 2001-11-08 22:39:26 dairiki Exp $'); + rcs_id('$Id: config.php,v 1.24.2.6 2001-11-08 23:15:43 dairiki Exp $'); // end essential internal stuff @@ -209,7 +209,11 @@ putenv ("LANG=$LANG"); bindtextdomain ("phpwiki", "./locale"); textdomain ("phpwiki"); - setlocale("LC_ALL", ""); + if (!defined("LC_ALL")) { + // Backwards compatibility (for PHP < 4.0.5) + define("LC_ALL", "LC_ALL"); + } + setlocale(LC_ALL, ""); } // end of localization function -- 2.45.0