• Resolved oldalgazda

    (@oldalgazda)


    I have discovered the issue when investigating this other problem:

    https://www.ads-software.com/support/topic/just-a-few-results-when-a-number-is-part-of-the-search-query

    So, there is a character in Unicode or UTF-8 which stands for non-breaking space. Now I know that you can enter this character with OPT+SPACE from OS X, but during the last 10 years I am dealing with websites I have never heard about it (except the  ?html entity of course), but it is a fact that if you are importing or copying documentation from some specific documentation software, this character can make it into your website: It looks exactly like a space, so nobody will notice it (for instance in some text editors if you set to show the invisible characters, this specific character will still be rendered as an empty space between characters.)

    So, what I am trying to describe is that if you search for:

    Firefox 22

    (with a space between the words)

    but the expression can be found on your website only in the form of

    Firefox?22

    (with a non-breaking space between the words)

    then Relevanssi will not find it, as it is identified (in a technically correct way) as a different string.

    https://www.ads-software.com/extend/plugins/relevanssi/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter oldalgazda

    (@oldalgazda)

    The form couldn’t handle the non-breaking character I wanted to enter at the second example.

    Plugin Author Mikko Saari

    (@msaari)

    Thanks, I’ll have to investigate this. Invisible characters are a pain, I’ve had enough trouble already with them.

    Plugin Author Mikko Saari

    (@msaari)

    Here’s a solution for you. Add this line to the relevanssi_remove_punct() function in lib/common.php:

    $a = str_replace(chr(194) . chr(160), ' ', $a);

    Then reindex, that should solve your problem.

    Thread Starter oldalgazda

    (@oldalgazda)

    Mikko,

    Thank you very much! I guess this change will be incorporated in the code base as well.

    Thanks again,
    József

    Plugin Author Mikko Saari

    (@msaari)

    Yes, this will be fixed in the next version.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Minor issue with non-breaking spaces’ is closed to new replies.