Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › No result for some spécial fields / strange results
This topic contains 9 replies, has 2 voices, and was last updated by Ernest Marcinko 7 years, 2 months ago.
- AuthorPosts
- June 29, 2016 at 11:07 pm #9319
Hi
first of all, thanks for your great plugin!
I encounter some problems of query results. The site where I work is composed of articles comprising a few special fields that I created with ACF: Pays, Format, Type de document, auteur.
Research must be done in the posts (content titles) and possibly their attachments (PDF, images, videos). The posts are indexed with categories, and special fields that behave as categories.I have chosen to activate the index table.
My configuration : Debian 8 + Apache 2.4 / WordPress 4.5.3 / DIVI Theme
My search module consists in two instances:
-one is a single search bar
-the other filters without search barThe part without search bar is intended to make lookups in the posts. It consists of two selectors (domaines, based on categories, pays, based on ACF) and two lists of checkbox (type of document, format, also created with ACF).
I would like to provide get results when I select individually any of the selectors, but also when I select a + b + c or a + c, etc.
Currently, only the country selector returns results, the other not, I don’t understand why. for example, if I check the PDF checkbox, I get nothing, whereas I should have posts which have PDF checked.Can you help me to solve these problems? I tried many combinations, including changing the links between fields AND to OR.
With regard to the single search bar, I get inconsistencies, some results normally appear, others should be displayed but not displayed.
Another problem: I experienced crashes of javascript, when previewing of the instances in the administration of the plugin.
In short, I really need your help 🙂
Kind regards
Rico from Skepsos teamp.s.: the ftp access is not configured for the moment.
-
This topic was modified 7 years, 2 months ago by
skepsos.
-
This topic was modified 7 years, 2 months ago by
skepsos.
-
This topic was modified 7 years, 2 months ago by
skepsos.
-
This topic was modified 7 years, 2 months ago by
skepsos.
Attachments:
You must be logged in to view attached files.June 30, 2016 at 12:49 pm #9334Hi!
I’ve checked the first search configuration and I have found a few issues, which I corrected:
1. On Filter par pays filter the first element was incorrect. It was:
Choisir un élément||Choisir un élément
while it should be simply:
||Choisir un élément
Otherwise the plugin will compare the field to the “Choisir un élément” string, which matches nothing of course.
2. The author filter value was empty, causing no matches, as most fields have author value set. I removed it, as it was not used at all.
3. Not particularly an issue, but the Allow results with missing custom fields, when using custom field selectors? option was enabled, while not neccessary in this case. Since you have empty values in your filters by default – they are not used unless the user selects an option.
It looks like it’s working for me now. Please also note that you are using complex ACF fields (checkboxes, selects), which might not work as expected. For some complex fields ACF only stores serialized data or reference data for obvious reasons, which is not the actual data values to search for (it’s not searchable). It should work in your case just fine, I just wanted to let you know.
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
June 30, 2016 at 1:36 pm #9335Hi
Thanks much for your help, good tips and reactivity! The part without search bar works now perfectly!
With regard to the searchbar, I encounter a little issue:
When I type “sar”, I get an article including the word “sary”, but when I type “Le sar” (like in the title of the article) article does not appear (screenshot 1). Similarly, if I type “parti”, I get the article (screenshot 2), but not when I hit “La parti”…Are there way to solve this issue?
Last question: in the first version of this research module, there was only a bar and its filters and options. But when I was typing nothing, selecting just the filters, no result was displayed. Are there a way so that there is actually only one bar with its options below?
Thanks in advance and bravo for the quality of your work!
Best regards,
Ricop.s.: I’d already put 5 stars on http://codecanyon.net, you deserve this note!
-
This reply was modified 7 years, 2 months ago by
skepsos.
Attachments:
You must be logged in to view attached files.June 30, 2016 at 1:40 pm #9338Hi again,
It’s a common issue, you can fix that by changing the search keyword logic: https://goo.gl/Cu5Egs
I suggest changing it to “AND”, it will give you more strict results in case of multiple keywords 🙂More information about keyword logic.
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
June 30, 2016 at 1:52 pm #9340Thanks a lot! I’ll try this.
But: My setup is now like in your screenshot, but it does not work…
I reproduce just one last question that I had published in my last reply:
in the first version of this research module, there was only a bar and its filters and options. But when I was typing nothing, selecting just the filters, no result was displayed. Are there a way so that there is actually only one bar with its options below?
If this is not possible, this is not serious, since everything works well 😉
Best regards,
Rico-
This reply was modified 7 years, 2 months ago by
skepsos. Reason: not working after change
June 30, 2016 at 2:00 pm #9342Yes, it is actually possible.
On the General Options -> Behavior panel, just reduce the Minimal character count to trigger search option to 0: https://i.imgur.com/REsxKVa.png
Then you can make the search bar visible on the Layout Options -> Search Box Layout panel: https://i.imgur.com/19RaWbU.pngThat way you only need 1 search bar.
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
June 30, 2016 at 2:14 pm #9343Yes! It’s done, thanks! Only the keyword logic problem persists…
Best regards,
RicoJune 30, 2016 at 2:26 pm #9345I’ve just noticed that you are also using the index table engine. The index table does not index words below length of 3, so “Le” , “La” are not matched at all, since they are not in the database.
While I do not recommend indexing words below 3 characters, as it may affect the precision of the index table engine, you can change that on the Index table options -> Advnaced panel: https://i.imgur.com/lgx2mbn.png
Best,
After lowering and saving the options, you will have to re-create the index table.
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
June 30, 2016 at 3:13 pm #9348Thank you very much. So, if I put 1 instead of 3 for example, will this be enough? If this may affect the results, I’ll still talk before my clients 😉
In any case, thank you for your help!
Kind regards
RicoJuly 4, 2016 at 10:20 am #9381Hi!
Yes, 1 should be fine 🙂
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
-
This topic was modified 7 years, 2 months ago by
- AuthorPosts
You must be logged in to reply to this topic.