From: Zheng Zhu Date: Fri, 24 Sep 2004 00:49:00 +0000 (+0000) Subject: updated warning about the UI switching code. X-Git-Tag: 1.5.0alpha1~1833 X-Git-Url: http://git.cyclocoop.org/fichier?a=commitdiff_plain;h=f30cb1cb19a0362ebbf9572698591b9934679043;p=lhc%2Fweb%2Fwiklou.git updated warning about the UI switching code. --- diff --git a/includes/Setup.php b/includes/Setup.php index 8e19b3e6d1..2ef0b4758d 100644 --- a/includes/Setup.php +++ b/includes/Setup.php @@ -219,19 +219,6 @@ if( $wgCommandLineMode ) { $wgUser = User::loadFromSession(); } -// FIXME : we don't know what the user entered (see SpecialPreferences.php [AV]) -if( count( $wgUserLanguages ) && - !empty( $wgUser->mOptions['language'] ) && - in_array( $wgUser->mOptions['language'], $wgUserLanguages ) ) { - // Change language of the site - $wgUserLanguageCode = $wgUser->mOptions['language']; - // we will load messages from file instead of from database - $wgUseDatabaseMessages = false; - # FIXME: THIS WILL BREAK NAMESPACES, VARIABLES, - # SEARCH INDEX UPDATES, AND MANY MANY THINGS. - # DO NOT USE THIS MODE EXCEPT FOR TESTING RIGHT NOW. -} - wfProfileOut( $fname.'-User' ); wfProfileIn( $fname.'-language' ); @@ -297,6 +284,23 @@ else { } wfProfileOut( $fname.'-MessageCache' ); + +# +# I guess the warning about UI switching might still apply... +# +# FIXME: THE ABOVE MIGHT BREAK NAMESPACES, VARIABLES, +# SEARCH INDEX UPDATES, AND MANY MANY THINGS. +# DO NOT USE THIS MODE EXCEPT FOR TESTING RIGHT NOW. +# +# To disable it, the easiest thing could be to uncomment the +# following; they should effectively disable the UI switch functionality +# +# $wgLangClass = $wgContLangClass; +# $wgLanguageCode = $wgContLanguageCode; +# $wgLang = $wgContLang; +# $wgMessageCache = $wgContMessageCache; +# + wfProfileIn( $fname.'-OutputPage' ); $wgOut = new OutputPage();