WordPress.org

Ready to get started?Download WordPress

Forums

Relevanssi - A Better Search
Search with single and double quotes is not working (7 posts)

  1. maorb
    Member
    Posted 3 years ago #

    I use your great Relevanssi for a Hebrew website.
    In Hebrew we have some words that contain single quote (') and also quotes (")
    When I try to search these words, the search phrase is being cut in that single/double quotes , so for i.e if I search word abc'd it will try to search abc.
    I assume that you escaped and removed all single/double quotes for security, but in the regular WP search this is not happening, so I assume it is something that can be fixed.

    I would be very appreciate your help solving this core issue.

    Many thanks

    http://wordpress.org/extend/plugins/relevanssi/

  2. Mikko Saari
    Member
    Plugin Author

    Posted 3 years ago #

    It's not security, but a standard search procedure of removing punctuation.

    In Relevanssi Premium, you can replace the punctuation removal function with your own and retain whatever punctuation you want, or choose what you want to remove and what to replace with spaces.

  3. maorb
    Member
    Posted 3 years ago #

    Thanks for your reply.
    The WP default search does not do it, if I use the default search and search for " or ', so these signs are being searched.
    More than that, Relevanssi does not only removes the " and ' signs, but also all characters that comes after it are being removed,
    so instead of at least looking for abcd instead of abc"d, it searches only for abc.
    Is this a premium feature to be able searching these signs?

  4. Mikko Saari
    Member
    Plugin Author

    Posted 3 years ago #

    WordPress doesn't remove the stuff after the apostrophes and quotes, but instead replaces the signs with spaces, splitting the word in two. That makes sense in some languages, but apparently not in Hebrew.

    In Premium you can adjust the way the punctuation is handled, so you can keep it or remove it so abc"d becomes abcd.

    This a Premium feature right now, but I think I'll add it to the free version in the next release, as it's just a question of adding a filter hook.

  5. maorb
    Member
    Posted 3 years ago #

    I checked in another site that I use the default WP search. WP does search as expected with single/double quotes, it does not split it to two words.

    I consider of purchasing the premium plugin, to support your great work, I just have to ask my client for the budget.

    Anyway, when do you expect that a next release of the free version will be available with this hook?

    Thank you Mikko!

  6. Mikko Saari
    Member
    Plugin Author

    Posted 3 years ago #

    No idea, I've got nothing else planned for the next version at the moment, Relevanssi has been a bit on the backburner recently.

    Hmm, I might consider changing the default behaviour with respect to quotes.

  7. maorb
    Member
    Posted 3 years ago #

    I changed the header("Location: to hidden input fields (as discussed in the other thread) and surprisingly now both orderby working and also searching words with " and ' signs inside them.
    Somehow, it appears that the header redirect did something wrong to the search...

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags