Added entry point to call the Traditional/Simplified Chinese conversion code in Langu...
authorZheng Zhu <zhengzhu@users.mediawiki.org>
Thu, 16 Sep 2004 20:25:12 +0000 (20:25 +0000)
committerZheng Zhu <zhengzhu@users.mediawiki.org>
Thu, 16 Sep 2004 20:25:12 +0000 (20:25 +0000)
includes/Parser.php

index d2af6df..2703fe4 100644 (file)
@@ -579,12 +579,18 @@ class Parser
        }
 
        function internalParse( $text, $linestart, $args = array(), $isMain=true ) {
+        global $wgLanguageCode, $wgLang;
+
                $fname = 'Parser::internalParse';
                wfProfileIn( $fname );
 
                $text = $this->removeHTMLtags( $text );
                $text = $this->replaceVariables( $text, $args );
 
+        if($wgLanguageCode == "zh") {
+             $text = $wgLang->convert($text);
+        }
+
                $text = preg_replace( '/(^|\n)-----*/', '\\1<hr />', $text );
 
                $text = $this->doHeadings( $text );