I am working on a wordpress site. That being said, I am using woocommerce and widget logic.
My overall goal is to have widget logic display custom widgets for each parent category and it’s children (sub catagories) and all the products under the main parent.
I don’t know how to add the correct code to make widget logic display on the parent and it’s children and the products. I can get the custom widget to display on the parent by it’s children categories by using this code:
is_product_category( array('PARENT', 'CHILD1', CHID2’ ) )
This works perfect; however, if I click on an actual product the custom widget disappears. I was hoping this code would work for not just the parent and children, but the products as well under the main parent. I’m so lost; I don’t know how to make this work with Wordpress conditional codes.
Any help would be appreciated.
Robert
Aucun commentaire:
Enregistrer un commentaire