0

I've recently added a plugin to have product filters (BeRocket) on my wordpress/woocommerce website. To display those filters on the page I made a widget and added it in my woocommerce.php page.

It's pretty much working as intended so far but it also displays the filters on the product pages since they're also generated from woocommerce.php..

Is there a way around that ? I just want those filters on the shop/category/tag pages, can I affect them directly without affecting the product pages ?

Any help appreciated. Best regards.

2 Answers 2

0

You need to use conditional tags of WooCommerce. Please have a look. In your case you can use this

if(!is_product()){
    //BeRocket Code
}
0

they have shortcodes that you place in the relevant archive templates that you want them to appear in.

this would need to be done in your child theme

get_shortcode('[ berocket_shortcode ]');

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.