Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Individual Priorities
This topic contains 9 replies, has 2 voices, and was last updated by skempenaar 2 years, 7 months ago.
- AuthorPosts
- October 20, 2020 at 3:52 pm #29917
HI Ernest,
How does priorities exactly work and how powerful is it. i’ve changed the value for 3 books from 100 to 101 and with a search “kinderen van het licht” these titles pop up first. the title of a product has a weight of 500 so i did not expect this to happen. a bug or some misconfiguration?
cheers
Attachments:
You must be logged in to view attached files.October 21, 2020 at 9:09 am #29930Hi,
That looks correct to me. Priorities always override the relevance values, as they are a separate ordering criteria. Prioritized matches will always be at the top of the results list.
Best,
The ordering queue of each result is the following:
Group Priority > Individual Priority > Post Type priority > Primary Ordering (relevance usually) > Secondary Ordering > ID ordering
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
October 21, 2020 at 9:25 am #29934thx for clearing this out. but why is “maffe meester daan” at the top of the results now? because its in the category “kinderen” ? do you know a way how to fix this? i’ve changed the priority because with the search “daan” for that book did not result in what it should. with the priority change this is fixed.
the same issue is relevant now for this search. what i want is that the second book is on the top. changing the title is not possible:) how would you do this? without this title popping with every seach related at the top beacuse its in a categorie or in a term.
as for my other topic since i’ve changed activiate results dropdown on 1 hit and show loading on suggestion box alot of people wait for the results. thx for this tip!
-
This reply was modified 2 years, 7 months ago by
skempenaar.
October 21, 2020 at 9:47 am #29936should date descending in secondary ordering after Relavance not fix this since the products is added later and is newer?
-
This reply was modified 2 years, 7 months ago by
skempenaar.
Attachments:
You must be logged in to view attached files.October 21, 2020 at 12:10 pm #29946The reason is, that is has priority 101 and the other results 100: https://i.imgur.com/08XL3ru.png
Best,
Matches with the higher priority will be always shown first – but only if they match, and regardless of what the phrase is.
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
October 21, 2020 at 1:02 pm #29952thx for clearing this. the image is very helpfull. is there a way to influance the default sorting then? since the priority option is way to powerfull for what we want.
for example:
the second result on top. why? because it’s a new title and our publishers want to sell this one more then the other.current setting
Primary ordering: Relevance i believe this is the best option since it always shows the results that a costumer wants.
Secondary ordering: Date descending. i hoped this would change the order the way we want it.If two elements match the primary ordering criteria, the Secondary ordering is used.
-
This reply was modified 2 years, 7 months ago by
skempenaar.
Attachments:
You must be logged in to view attached files.October 22, 2020 at 12:35 pm #29965Well, I’m afraid the only way in this case by making a direct modification to the core plugin code, but I am not sure if in that case it is possible, as the index table has a hard time working with exact matches.
Anyways, please try this modification:
Best,
1. Open the wp-content/plugins/ajax-search-pro/includes/classes/search/class-asp-search-indextable.php file on your server
2. Replace it’s contents with this
3. Save and clear all caches
If all goes well, this may boost the exact title relevances. Please be careful, I was not able to test this modification yet.
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
October 22, 2020 at 5:12 pm #29967thx i believe this works!. this is wound work as a snippet in functions or copy the file to child theme?
on our testserver im getting this error in debug mode
Warning: count(): Parameter must be an array or an object that implements Countable in /mnt/env/rjvps/development/public_html/wp-content/plugins/ajax-search-pro/includes/classes/search/class-asp-search-indextable.php on line 475
October 23, 2020 at 8:17 am #29975I think I just made a mistake there, that causes the error, this variation should remove that.
This does not work as a custom code snippet unfortunately. But I think this is going to be a permanent change in the upcoming release, so you don’t have to worry about it.
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
October 23, 2020 at 9:25 am #29980brilliant. works like charm!. i think its a very good update for the plugin:)
Attachments:
You must be logged in to view attached files. -
This reply was modified 2 years, 7 months ago by
- AuthorPosts
You must be logged in to reply to this topic.