changes
This commit is contained in:
@@ -25,14 +25,9 @@ class DontShowProductsOnShopLandingPageAction extends RadAction
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Remove everything hooked to the product loop
|
|
||||||
remove_all_actions('woocommerce_before_shop_loop');
|
remove_all_actions('woocommerce_before_shop_loop');
|
||||||
remove_all_actions('woocommerce_shop_loop');
|
remove_all_actions('woocommerce_shop_loop');
|
||||||
remove_all_actions('woocommerce_after_shop_loop');
|
remove_all_actions('woocommerce_after_shop_loop');
|
||||||
|
|
||||||
// Also prevent product loop rendering itself
|
|
||||||
remove_all_actions('woocommerce_before_main_content');
|
|
||||||
remove_all_actions('woocommerce_after_main_content');
|
|
||||||
remove_all_actions('woocommerce_no_products_found');
|
remove_all_actions('woocommerce_no_products_found');
|
||||||
|
|
||||||
add_action('pre_get_posts', function ($query) {
|
add_action('pre_get_posts', function ($query) {
|
||||||
|
|||||||
Reference in New Issue
Block a user