From: Zheng Zhu Date: Mon, 20 Sep 2004 05:22:45 +0000 (+0000) Subject: added a language variant field to the page rendering hash, but only for languages... X-Git-Tag: 1.5.0alpha1~1942 X-Git-Url: http://git.cyclocoop.org/%24action?a=commitdiff_plain;h=539fc27b10ab37e229ae6b8b3326670607f899cc;p=lhc%2Fweb%2Fwiklou.git added a language variant field to the page rendering hash, but only for languages that support multiple variants. --- diff --git a/includes/User.php b/includes/User.php index 332c6fce40..a38f60c178 100644 --- a/includes/User.php +++ b/includes/User.php @@ -814,6 +814,7 @@ class User { } function getPageRenderingHash() { + global $wgLang; if( $this->mHash ){ return $this->mHash; } @@ -830,6 +831,12 @@ class User { $confstr .= '!' . $this->getOption( 'date' ); $confstr .= '!' . $this->getOption( 'numberheadings' ); + // add in language variant option if there are multiple variants + // supported by the language object + if(sizeof($wgLang->getVariants())>1) { + $confstr .= '!' . $this->getOption( 'variant' ); + } + $this->mHash = $confstr; return $confstr ; }