This website uses cookies to personalize your experience. By using this website you agree to our cookie policy.

Some posts show full content of post in search results box

Home Forums Product Support Forums Ajax Search Pro for WordPress Support Some posts show full content of post in search results box

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #31056
    bzed82bzed82
    Participant

    Hello,

    When using the search box – the results that come up sometimes show full content of the post, instead of just the 200 characters I’ve chosen.

    This happens for a search term like “EU Citizen”.

    I will attach screenshots to see different between expected results and the results coming up for “EU Citizen”.

    Thank you.

    #31060
    Ernest MarcinkoErnest Marcinko
    Keymaster

    Hi,

    Thank you very much for the details, it helped us a lot!

    This was indeed a yet unknown bug, I was able to replicate the issue on our test server as well. The issue was caused by the fact that the algorithm tries to look for the first of the search keyword, in case of “eu citizen”, it looks for the context of “eu” first. However the minimum keyword length was defined as 4 here, in which case the keyword “eu” was ignored (length = 2), and an empty string was passed to the function. It caused to return the whole description without shortening the length.
    I have corrected this problem on your server via the plugin editor, and I will make sure to implement this fix in the upcoming release, so you don’t have to worry about it. It should be all right now.

    If I may suggest a different logic setup, I would recommend this for the best possible, and most relevant results: https://i.imgur.com/rlbAq2W.png

    #31063
    bzed82bzed82
    Participant

    Thank you very much. I changed the logic based on your suggestion.

    #31066
    Ernest MarcinkoErnest Marcinko
    Keymaster

    You cannot access this content.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.