Title: Wrong page when search string is empty
Last modified: May 11, 2021

---

# Wrong page when search string is empty

 *  Resolved [Borgtex](https://wordpress.org/support/users/borgtex/)
 * (@borgtex)
 * [5 years ago](https://wordpress.org/support/topic/wrong-page-when-search-string-is-empty/)
 * Hi, I implemented the filter for the product search page with checkboxes, and
   it all works fine except when the search string is empty. i.e.:
 * I start with this:
 * [https://www.mydomain.com/?s=&post_type=product](https://www.mydomain.com/?s=&post_type=product)
   
   and it shows all the products
 * but when I try to filter by “wine” using your plugin, it changes the url to this:
   
   [https://www.mydomain.com/?yith_wcan=1&post_type=product&product_cat=wine](https://www.mydomain.com/?yith_wcan=1&post_type=product&product_cat=wine)
 * removing the “s” parameter and thus getting out of the search page.
 * Strangely, the url of the link besides the checkbox is somewhat correct:
    [https://www.mydomain.com/shop/?yith_wcan=1&s&product_cat=wine](https://www.mydomain.com/shop/?yith_wcan=1&s&product_cat=wine)
 * Is there any way I can prevent this page change, allowing an empty search string?
 * Thank you

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Support [Giuseppe Madaudo](https://wordpress.org/support/users/askmagic/)
 * (@askmagic)
 * [5 years ago](https://wordpress.org/support/topic/wrong-page-when-search-string-is-empty/#post-14425399)
 * Hi there,
    this is the normal behavior of the plugin and I’m sorry cannot be 
   changed.
 *  Thread Starter [Borgtex](https://wordpress.org/support/users/borgtex/)
 * (@borgtex)
 * [5 years ago](https://wordpress.org/support/topic/wrong-page-when-search-string-is-empty/#post-14426322)
 * Oh I see. I suppose i’ll have to look into the source code to find the problem
   with the ajax call and make the corrections to make it work for my installation.
 * Thanks anyway
 *  Plugin Support [Andrea Grillo](https://wordpress.org/support/users/agengineering/)
 * (@agengineering)
 * [4 years, 12 months ago](https://wordpress.org/support/topic/wrong-page-when-search-string-is-empty/#post-14448657)
 * Thanks to you, too.
    Have a nice day.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Wrong page when search string is empty’ is closed to new replies.

 * ![](https://ps.w.org/yith-woocommerce-ajax-navigation/assets/icon-256x256.gif?
   rev=3129944)
 * [YITH WooCommerce Ajax Product Filter](https://wordpress.org/plugins/yith-woocommerce-ajax-navigation/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/yith-woocommerce-ajax-navigation/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/yith-woocommerce-ajax-navigation/)
 * [Active Topics](https://wordpress.org/support/plugin/yith-woocommerce-ajax-navigation/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/yith-woocommerce-ajax-navigation/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/yith-woocommerce-ajax-navigation/reviews/)

## Tags

 * [wrong page](https://wordpress.org/support/topic-tag/wrong-page/)

 * 3 replies
 * 3 participants
 * Last reply from: [Andrea Grillo](https://wordpress.org/support/users/agengineering/)
 * Last activity: [4 years, 12 months ago](https://wordpress.org/support/topic/wrong-page-when-search-string-is-empty/#post-14448657)
 * Status: resolved