Search bar is displaying a 404 error
-
Hi, my search bar is not properly working. AJAX is showing the results well when I start typing in the search bar. However, it displays a 404 error when I type something in the search bar and I click enter or VIEW ALL RESULTS
Example: https://stonersrotation.com/news?s=cbd&post_type=post
Site: https://stonersrotation.com/news
Please advise. Thanks!
I just realized it is because I have a 301 redirect from home to /news, so the search results automatically redirects to https://stonersrotation.com/news>?s=cbd&post_type=post instead of https://stonersrotation.com/?s=cbd&post_type=post (without /news/).
Is there an easy way to fix that? I know it will work once I remove the redirect in htaccess from home to /news, but I’d like to keep the redirect for at least a few more months.
Thank you!
Hello,
Unfortunately, this is the way the WordPress search works and our theme does not influence this functionality.
Best Regards
Hello, what was the solution? I have the same problem, can you help me?
Hello,
The search form is based on the default Woocommerce search.
Please make the full backup of your site as well as the Theme settings export and check the issue on the Storefront theme to detect if our theme causes the problem. Storefront is a free theme developed by WooСommerce.
Best Regards