Search stopped working – no results found
-
My client reported that the search on their website stopped working on 18th of this month.
I’m seeing the same problem. It’s been working fine for months, but now it returns ‘No results!’.
I’ve updated to the very latest version released today and it’s still not working.
I noticed in another recent post you mentioned a potential issue with WooCommerce – I’m not using WooCommerce, but I have a Custom Post Type using ‘product’ as it’s slug.
-
Hi!
Can you try resetting the search settings to defaults (if reconfiguring is not too much hassle)? You can do it under the Maintenance submenu -> Reset all options to defaults button.
In another case an input validation has failed because an option value was set incorrectly. If you can’t reset and reconfigure, or if that doesn’t help, then can you share a link where I can see the problem?
In this case there is likely no script error, but something I have missed during the migration, something within the configuration buried somewhere.
All the best,
ErnestThat’s not made any difference I’m afraid, and there are no errors logged.
Here’s a link: https://winster-hose.co.uk/
Use the search button top right to show the search bar.Thank you!
I don’t see anything inherently wrong on the front-end, the parameters look all right too.
- Can you please open the search settings and save them without changing anything? If there was a data corruption somewhere it should fix it.
- If that doesn’t work, then can you take a screenshot of the General Options -> Post type search (it may need 2 screenshots to fit) panel for starters? Maybe there is something I can spot.
All the best,
ErnestHi Ernest,
Saving the settings has made no difference unfortunately.
-
This reply was modified 2 months, 3 weeks ago by
sleepcreaterepeat.
Okay, the screenshot looks all good there.
Let’s try two things to try to isolate the issue.
- First, please go to the Advanced -> Exclude options panel and make sure that no Exclusions are set, especially the Exclude hidden search/catalog options (if they are displayed). If there was anything at all excluded, then please remove it and test if that works.
- If the above doesn’t work, then please change the post type from product to post and page temporary and check if that starts to show any results. This may reveal if the issue is isolated to the product post type only. I suspect this may actually reveal something.
Let me know!
All the best,
ErnestAdvanced -> Exclude was excluding ‘uncategorized’, I removed it and it made no difference.
I changed the post type from product to post and page and it’s now returning results, although not from the ‘products’ CPT, and more slowly than usual.Thank you, there is a similar report here, and I think I have isolated the issue.
I was able to replicate it with an almost identical setup and is related to the category exclusions. Expect a fix either tomorrow or monday, let’s hope it will resolve it.
All the best,
ErnestThank you, Ernest – I look forward to trying the fixed version.
I almost forgot, if you have a code snippets plugin, then can you please try adding this as a PHP snippet:
add_filter('asl_query_args', function($args) {
$args['_post_allow_empty_tax_term'] = true;
return $args;
}, 10, 1);This should resolve the issue. If you try this, please let me know if it works, it would confirm the problem.
All the best,
ErnestThanks again, Ernest. That snippet has indeed fixed the issue 🙂
Thank you very much for the feedback, you were super helpful!
Now I’m confident about the fix, to be expected tomorrow/monday.
I’m keeping this topic unresolved for now, just in case I mess up something in the update.
All the best,
ErnestHi!
Version 4.14.3 was released, it should resolve this issue without the need of the code snippet.
All the best,
ErnestThanks, Ernest – it’s working fine with just the updated plugin now
Thank you very much for the feedback and patience, I really appreciate it!
In case you haven’t, feel free to rate the plugin if you like it, it helps me greatly!
Issue marked as resolved.
All the best,
Ernest
You must be logged in to reply to this topic.