Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › custom search filter
- This topic has 12 replies, 2 voices, and was last updated 9 years, 8 months ago by
khalid.
-
AuthorPosts
-
September 9, 2016 at 1:49 pm #10040
khalid
ParticipantHi, I am replacing the current search on my site. if you check I have the search result filtered as articles and companies
http://screencast.com/t/juPUGX3ZJo
*companies is pages.
How I can implement same filter with Ajax search pro. ?
September 9, 2016 at 1:57 pm #10042Ernest Marcinko
KeymasterHi,
I’m assuming the articles and companies are different custom post types?
In this case you are looking for results grouping by post type: http://i.imgur.com/iuB4zfw.pngIf they are the same post type, but in a different category, then grouping by category is the way to go: http://i.imgur.com/YO8mHsE.png
September 9, 2016 at 2:01 pm #10043khalid
ParticipantYou cannot access this content.
September 9, 2016 at 2:05 pm #10044khalid
Participantand yes,, articles is posts. and companies are pages.
September 9, 2016 at 2:13 pm #10045Ernest Marcinko
KeymasterHi,
Thank you for the details, I have found the problem. The mixed results ordering was activated, which appears to have caused a yet unknown bug. I’ve turned that option off, as it’s not needed for grouping, and it fixed the problem 🙂
September 9, 2016 at 2:19 pm #10047khalid
ParticipantThank you. I really appreciate you help.
just last thing.. is there is possible to order the search result by. pages (company’s ) first then posts (articles).
Or view 5 result limit from each.
September 9, 2016 at 2:21 pm #10049khalid
Participantalso, is there is possible to change the tittle here to companies and articles : http://screencast.com/t/9vaQ3udWL
September 9, 2016 at 2:24 pm #10050Ernest Marcinko
KeymasterHi,
You can change the order and the text as well on the same options panel: http://i.imgur.com/mcCNMmW.png
September 9, 2016 at 2:29 pm #10053khalid
Participantthank you very much. just try to search here : http://screencast.com/t/omN02PsS
is there possible to display companies first. then article.
September 9, 2016 at 2:34 pm #10054Ernest Marcinko
KeymasterHi,
The companies are displaying first, if there are company results for the actual search query within the limit.
If you want to prioritize some results over others, you can use the priorities function as well: https://goo.gl/4Z7xbj
September 9, 2016 at 2:41 pm #10056khalid
ParticipantThank you..
just please check to search here : http://marketexclusive.com/search-test/
for FD, then FDI
http://screencast.com/t/K3WHwWv779
with FD search the result all from articles , and with FDI the result from companies and articles which what I need.
September 9, 2016 at 3:12 pm #10059Ernest Marcinko
KeymasterI will try to explain why it’s working like that:
The limit for post types is set to 10. When searching for “FD” it returns over 10 more relevant results for the articles than the companies so those are displayed. The limit applies to all post types in overall, not separately, as they are stored in the same database table. The more relevant items are displayed first, regardless of the post type. (the results count is not distributed evenly by post type, it’s not possible by a single query)I’ve noted this as a possible feature in the next release, as it would be very useful. Of course I will have to investigate first how a solution would affect the overall performance.
September 9, 2016 at 3:14 pm #10060khalid
Participantthanks
-
AuthorPosts
- The topic ‘custom search filter’ is closed to new replies.