Your cart is currently empty!
WooCommerce Product Search redirecting to home page after search submit
—
by
Hi,
After I click enter on my shop page search (https://tmsedm.co.uk/products/) it redirects me to https://tmsedm.co.uk/ with the search query on the end of the url.
Why is this happening? Am I missing a setting?
Many thanks
Posted in General Questions
Comments
3 responses to “WooCommerce Product Search redirecting to home page after search submit”
Hello,
I tried searching on the page you linked to and can confirm that this is the correct search behaviour. The search uses AJAX to load the results dynamically (without the need to reload the page), hence the parameters in the URL.
I also noticed that you’re using a different search in your top search box on the main page and I’d recommend utilising WooCommerce product search there too, since that one throws a JS error in the console. You’d need to enable the Replace the standard product search form option on the WooCommerce > Settings > Search page.
Here’s the documentation page on how to integrate the search with your theme, in case you happen to stumble upon any issues -> https://docs.woocommerce.com/document/woocommerce-product-search/themes/
Let me know if this helps!
Cheers,
Denitsa
Hi,
If its using AJAX should it be changing the products on that page when I start typing? As this doesn’t happen either.
I don’t have the replace the standard product search form option on the WooCommerce > Settings > Search page. I just have Search Weights.
I have removed the other search plugin.
Many thanks
Hi again,
You are right, the plugin displays a menu below the search form with the results as you are typing, see a screenshot here -> https://pasteboard.co/Ig2NhyLg.png
There are various settings that the widget provides for customizing the search behaviour, like specifying a delay when displaying the results, changing the URL, etc. There’s a doc page for that too, if you’d like to take a look and explore the options -> https://docs.woocommerce.com/document/woocommerce-product-search/widgets/product-filter-search/
Sorry, I should have been more clear in my previous answer regarding the Replace the standard product search form option – it’s found under WooCommerce > Settings > Search in the General tab. The documentation page for the plugin settings has some screenshots that show that option -> https://docs.woocommerce.com/document/woocommerce-product-search/settings/general/
Cheers,
Denitsa