I have a question regarding the product category. I have a category like that:
-electronic -- laptop -- mobile then I want to create a logic for all product under electronic, I use is_product_category( 'electronic' ), but it doesn't work for electronic, it only works when URL is mywebsite.com/product-category/electronic when I use mywebsite.com/product-category/electronic/mobile/ it doesn't work. Should I use the following codes or there is another option:
is_product_category( 'laptop' ) is_product_category( 'mobile' ) https://stackoverflow.com/questions/66734013/target-woocommerce-product-category-archive-pages-from-a-child-category-term March 21, 2021 at 11:13PM
没有评论:
发表评论