UI > search > Bug (done?)

Searching for "Поддръжка" does not work / #1368

Summary

done?
Jul 12, 2006
100%
Jul 12, 2006 / pixtur
Nov 17, 2008 / pixtur
 

Attached files

No files uploaded
from http://www.streber-pm.org/phpBB2/viewtopic.php?t=205&highlight=

I'm using streber v 0.063 with my native language - "cyrillic". All is working fine, but the search is not working when I use cyrillic letters.

This is what I got for searching "Поддръжка" (support on English):

Quote:

No search results for `0`

sorry. Could not find anything.

Due to limitations of MySQL fulltext search, searching will not work for...
  • words with 3 or less characters
  • Lists with less than 3 entries
  • words containing special charaters

It seems for me that this is related to the character conversion.

P.S.
Maybe it is not a bug, but ... just to share it

\\

Issue report

Minor
Not available
WinXP / Firefox 1.5
v0.061
 

7 Comments

pixtur

Oct 13, 2006

array

Oct 31, 2008
View comment
This issue exists because of using Unicode (2bytes encoding).

so I replaced original code in /std/common.inc.php
with this one:
function asMatchString($str) {
    return preg_replace("/[\\\<\>\`_\"]/",,$str);//preg_replace("/[^0-9a-z_\*! ]/i",,strtolower($str));
}

This is just temporary solution for me. And it works from time to time :D

pixtur

Oct 31, 2008
version 2
interessting...
Sounds like a good patch for v0.081

pixtur

Nov 3, 2008

array

Nov 4, 2008
View comment
Ooops... post filter cut regular expression in post above.
Trying to post it again.

from /std/common.inc.php

function asMatchString($str) {
    return preg_replace("/[\\\<\>\`_\"]/",'',$str);
}

array

Nov 4, 2008
View comment
Hm...
so just use it:
function asMatchString($str) {
    return asCleanString($str);
}

pixtur

Nov 5, 2008
ah... right...
I already understood that the regex was rendered invalid because of stripped backslashes. :) But your code is more optimal...

 

Comment / Update