New answers tagged

1

$currentCat = get_queried_object(); if ( $currentCat->term_id == 64 || $currentCat->parent == 64 ) { dynamic_sidebar('Distillati Sidebar'); } I solved in this way: it works!


0

Not sure how you're going to be calling these categories as you could do it programmatically using 'child_of'=>$parentCatID but you'd need to check the WooCommerce documentation to see exactly how. To answer your question, is_product_category() will accept an array of categories, so the following should work: if( is_product_category( array( 'wine', 'white-...


2

First you have to register the sidebar if you haven`t done yet with register_sidebar( $args );, then display it in the page: dynamic_sidebar( $sidebar ); see documentation at: https://codex.wordpress.org/Sidebars


Top 50 recent answers are included