Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Live search returns some posts with title starting with searched term only
- This topic has 10 replies, 2 voices, and was last updated 9 years ago by
AlessandroF.
-
AuthorPosts
-
May 8, 2017 at 5:47 pm #13017
AlessandroF
ParticipantLive search returns some posts with title starting with searched term only, but not even all of them.
Index table enabled.
This is a multi-site install but I configured no cross-site search.Try searching “tavola”:
– no live search result
– good suggestions
– good regular search (regular WP search) https://www.foodweb.it/?s=tavolaTry searching “caprotti”
– 1 match only in live search
– good regular search (regular WP search) https://www.foodweb.it/?s=caprottiMay 9, 2017 at 11:31 am #13028Ernest Marcinko
KeymasterHi,
I’m guessing this might be only a configuration related issue, but I can’t tell, unless I’m able to see it.
Can you please add temporary back-end and FTP details to your ticket. I would like to check the search and the index table configuration and debug the source if neccessary. Thank you!
May 9, 2017 at 5:41 pm #13031AlessandroF
ParticipantYou cannot access this content.
May 10, 2017 at 12:23 pm #13039Ernest Marcinko
KeymasterHi Alessandro,
No problem, let’s try it this way. I’ve imported the search instance, and found only one possible issue within the configuration. On the Frontend Search settings -> Post tags panel the tag filters are enabled, but not used. Can you please turn them off?: http://i.imgur.com/m9fjcol.png
My guess is that there might be a conflict whenever this filter is turned on, but the settings are hidden. Let me know if that changes anything.
May 10, 2017 at 1:00 pm #13040AlessandroF
ParticipantI turned them off, saved, cleared server and browser cache.
Something changed but not fixed yet:
– “caprotti” live search now returns 6 post with title starting width “caprotti” (correct results are much more and live search limit is set to 10)
– “tavola” (and many others) live search still returns no resultMaybe there’s a post_title LIKE ‘<search_term>%’ sql condition somewhere.
I tried switching to regular engine but I get results from the other blog switch is in different language (english vs italian).
I’ve quickly reverted to indexed table.I tried to investigate plugin code mostly includes/classes/search/class-asp-search-indextable.php from line 390 forward (423 picked my interest first), but couldn’t find a clue.
May 11, 2017 at 10:35 am #13050Ernest Marcinko
KeymasterMay I ask which multi language plugin do you use?
Because I see you have the custom ajax handler enabled, which very likely won’t work with any of them. I would suggest turning that off to see how that changes the outcome: http://i.imgur.com/j6ia999.png
What happens if you create a new search instance, with the default configuration, and only change the engine to index table? If that works, then at least we know it’s something with the search config. If not, then it’s probably the index table config.
I feel like this is something very obvious, but unfortunately the importing may not display all the options – for example category/term exclusions and filters, if the same categories and objects with the same IDs does not exist on my installation as well, obviously.
May 11, 2017 at 12:29 pm #13057AlessandroF
ParticipantI’ve done many tests starting from your suggestions and I think I found the original problem.
I have a multisite installation:
– http://www.foodweb.it (own custom theme, own original content, same plugins, many copied configurations, italian language)
– http://www.italianfood.net (own custom theme, own original content, same plugins, many copied configurations, english language)I created http://www.foodweb.it first then when I created http://www.italianfood.net I exported ASP instance configuration from http://www.foodweb.it and imported it in the new site.
Then I changed ASP instance in http://www.italianfood.net . Very few changes, mainly labels change (translation) and Multisite Options to http://www.italianfood.net .
I experienced some problems with labels translation but I had no time to investigate.Now I found that ASP instances get syncronized/replicated/shared in http://www.foodweb.it and http://www.italianfood.net
Labels settings, Multisite Options, all settings.
New test instance created in http://www.foodweb.it (as you suggested) appear in http://www.italianfood.net too.Resetting Multisite Options to default (no blog dragged to right list) fix live search results for both sites but labels problem is still present.
How can I separate sites?
As a quick fix I’ve duplicated current instance (export+import) and use one for http://www.foodweb.it and another for http://www.italianfood.net
Now I’m configuring the new instance for http://www.italianfood.net needs and fixing all ASP instance references (theme css, ecc.).
There’s a better way?Thanks,
AlessandroMay 11, 2017 at 12:43 pm #13059Ernest Marcinko
KeymasterHi Alessandro,
Well, the instances are indeed shared, but problems can arise whenever there are some advanced features in use – like category/term exclusions, filters etc.. – as most of these objects are not shared across the multisite blogs.
If the network is not too big, this should be the best solution. If one single search instance can handle all requirements, and the only issue is the language of the labels, then it is possible actually to translate the labels using PolyLang or WPML string translations: https://wpdreams.gitbooks.io/ajax-search-pro-documentation/content/translating_components.html
May 11, 2017 at 2:09 pm #13064AlessandroF
ParticipantOk, seeing configuration not in network admin but in site admin I misunderstood.
What configurations are shared?
Instances only?
Index table indexes?
Other configurations?Thanks,
AlessandroMay 11, 2017 at 2:57 pm #13067Ernest Marcinko
KeymasterHi Alessandro,
Everything is shared across the network, as the plugin uses separate database tables to store the configuration and everything else.
May 11, 2017 at 3:16 pm #13068AlessandroF
ParticipantOk, so no wp_2_* tables.
I found that Index Table “Stop Words” configuration is not shared so I misunderstood.Now all is fixed.
Thanks for you help,
Alessandro -
AuthorPosts
- The topic ‘Live search returns some posts with title starting with searched term only’ is closed to new replies.