dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
20f00fa
)
convert to simplified Chinese before for searching and indexing.
author
Zheng Zhu
<zhengzhu@users.mediawiki.org>
Thu, 25 Nov 2004 03:17:05 +0000
(
03:17
+0000)
committer
Zheng Zhu
<zhengzhu@users.mediawiki.org>
Thu, 25 Nov 2004 03:17:05 +0000
(
03:17
+0000)
languages/LanguageZh.php
patch
|
blob
|
history
diff --git
a/languages/LanguageZh.php
b/languages/LanguageZh.php
index
f01e373
..
59afd08
100644
(file)
--- a/
languages/LanguageZh.php
+++ b/
languages/LanguageZh.php
@@
-108,11
+108,17
@@
class LanguageZh extends LanguageZh_cn {
function stripForSearch( $string ) {
$fname="zhsegment";
wfProfileIn( $fname );
+ //always convert to zh-cn before indexing. it should be
+ //better to use zh-cn for search, since conversion from
+ //Traditional to Simplified is less ambiguous than the
+ //other way around
+ $string = $this->autoConvert($string, 'zh-cn');
$t = $this->mZhClient->segment($string);
$t = LanguageUtf8::stripForSearch( $t );
wfProfileOut( $fname );
return $t;
}
+
}
?>