• Resolved formlos

    (@formlos)


    We added a custom post type on our page (https://spielwiese.eigenstil.de). I also checked the checkbox for this custom post type to be searched in the plugin options. (You can verify this, when searching for the word “tolle” on the page).

    Here is the problem

    When I search for a part of a word, or if I search for the singular term of a word, the search results don’t show all the possible results. Example:

    • Searching for “anwendung” will result in only 1 search result – although this particular string occurs in ALL of the posts (as a substring), that are visible on the front page.
    • When I deactivate the plugin and search for “anwendung” all the results are shown as expected.

    Question: Is there some setting in the plugin, that I am missing? I already checked every single setting but none of the seem right. Or is it just not possible to search for “substrings” with this plugin?

    The page I need help with: [log in to see the link]

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Ajay

    (@ajay)

    You might need to turn on BOOLEAN mode in the settings page.

    Thread Starter formlos

    (@formlos)

    Thanks @ajay for your reply! I already tried this but to no avail. But I switched it on, please check these results: https://spielwiese.eigenstil.de/?s=anwend

    Caching is deactivated (https://spielwiese.eigenstil.de/wp-content/uploads/2023/01/screenshot-2023-01-30-094112.png).

    • This reply was modified 1 year, 9 months ago by formlos.
    Plugin Author Ajay

    (@ajay)

    I suspect that is actually because it is the partial word point.

    I think it works if you use anwendung* which is how mySQL FULLTEXT search supports it.

    The problem with automating this approach is that it could end up releasing more results than ideal particularly for common words.

    Thread Starter formlos

    (@formlos)

    Ok, thank you for your answer. If I get you right, my request is only solveable when using the * character in the frontend. (And I think this is not a viable solution for not so techy people).

    (Actually this makes the plugin show less results with the standard settings. This should be mentioned somewhere in the docs or in the plugin.)

    It would be very cool, if there would be a setting in the plugin (or at least a filter/action) for switching this on.

    Plugin Author Ajay

    (@ajay)

    When you say less results vs standard settings, what are you referring to by standard? Do you mean the default WordPress search?

    On the filter, please see this file which pulls out the search query or the search terms. https://github.com/WebberZone/better-search/blob/master/includes/main-functions.php

    Depending on your use-case you could amend the query to add the *. In this case you might probably want to consider which terms, if any are the most likely ones people are searching for. E.g. check what searches are tracked and then use those keywords only to rewrite the query if the word is present.

    Thread Starter formlos

    (@formlos)

    Yes, I mean less results compared to the default WordPress search. I know, this is kind of a philosophical question, if less results are “better” or “worse” when it comes to the default WordPress search ?? (especially on WordPress sites with a lot of content, e.g. 200+ posts).

    But considering that people searching for specific (more detailed/longer) queries find MORE results than people using a “shorter” query, this seems a bit unexpected and unintuitive (from a user perspective).

    Thanks for your ideas

    Plugin Author Ajay

    (@ajay)

    I agree. It is philosophical. Ideally you want to use a plugin like mine to get more relevant results which might definitely be lower in number than the default search. Not sure I’d put less results as a marketing point for the plugin ??

    Thread Starter formlos

    (@formlos)

    Yes, “less results” as a marketing point for the plugin could be a dealbreaker ??

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Partial words (e.g. plural / singular / stems) are not found’ is closed to new replies.