diff options
Diffstat (limited to 'inc/indexer.php')
-rw-r--r-- | inc/indexer.php | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/inc/indexer.php b/inc/indexer.php index 9cf079261..526c8db05 100644 --- a/inc/indexer.php +++ b/inc/indexer.php @@ -221,7 +221,14 @@ function idx_getPageWords($page){ list($page,$body) = $data; - $body = strtr($body, "\r\n\t", ' '); + $body = strtr($body, + array( + "\r" => ' ', + "\n" => ' ', + "\t" => ' ', + "\xC2\xAD" => '', //soft-hyphen + ) + ); $tokens = explode(' ', $body); $tokens = array_count_values($tokens); // count the frequency of each token |