Single search result problematic redirect
-
Hi,
After spending hours trying to figure out why xstore product filtering doesn’t filter all search results with this plugin, I think I finally realized the issue.
It seems that on search results page containing post_type=product in the url, whenever the filtering has only one product to display (from multiple products displayed in the search results), it won’t filter the products to display the single product on the search results page because the search plugin default behavior is to go directly to the single product page whenever there’s only one product in the results.
To resolve this, it would be highly appreciated if you could please let me know what I can add to functions.php in order to modify this default behavior so that whenever a product search has only one search result it would display that product on a search results page instead of redirecting straight to that product page.
Thank you very much and have a fantastic year!
- You must be logged in to reply to this topic.