From: Zheng Zhu Date: Thu, 27 Jan 2005 21:59:40 +0000 (+0000) Subject: Allow simple comments for each translation rule in MW:Zhconversiontable X-Git-Tag: 1.5.0alpha1~836 X-Git-Url: http://git.cyclocoop.org/%24self?a=commitdiff_plain;h=70cef3446d95bba07552321ca51e7bce54bebea2;p=lhc%2Fweb%2Fwiklou.git Allow simple comments for each translation rule in MW:Zhconversiontable --- diff --git a/languages/LanguageZh.php b/languages/LanguageZh.php index 9b65a82c4b..a5b1315e35 100644 --- a/languages/LanguageZh.php +++ b/languages/LanguageZh.php @@ -189,7 +189,9 @@ class LanguageZh extends LanguageZh_cn { $m = explode( '=>', $t ); if( count( $m ) != 2) continue; - $ret[trim($m[0])] = trim($m[1]); + // trim any trailling comments starting with '//' + $tt = explode('//', $m[1], 2); + $ret[trim($m[0])] = trim($tt[0]); } } $parsed[$key] = true;