Support » Plugin: Relevanssi - A Better Search » Synonyms without "OR" (or: how to turn ß into ss)

  • Resolved fert


    I am using Relevanssi on an English WordPress install but the website is German. I do not use the official German translation because of its poor performance.

    When users search for words with specific German characters like “ß” they don’t get the results for words containing “ss” instead. This is important not only for those users who are not sure about the spelling but also those from countries like Switzerland who use German but don’t have this character on their keyboard (apparently).

    Is there a way to get Relevanssi to treat ‘ß’ like ‘ss’? It does work for umlauts…

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Mikko Saari


    add_filter('relevanssi_remove_punctuation', 'ss_conversion', 9);
    function ss_conversion($a) {
        $a = str_replace('ß', 'ss', $a);
        return $a;

    Add this to your functions.php and rebuild the index, that should do the trick.

    The umlauts are automatically handled by the MySQL matching, but looks like ß isn’t.

    Wow – thank you!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Synonyms without "OR" (or: how to turn ß into ss)’ is closed to new replies.