• Hi there, thank you for the plugin, it’s great! Question: I want to hide (or show) specific menu items for product pages. I’ve tried to create two categories and hide those accordingly, but to no avail.

    Basically, my menu now reads:

    My Aleppo | My Aleppo Shop | My Radius | My Radius Shop

    For the product category “Radius”, I want to hide My Aleppo | My Aleppo Shop, so I have put ! is_product_category( ‘Radius’ ) in the control panel, but to no avail.

    What am I doing wrong?

    • This topic was modified 8 years, 1 month ago by wurgi.
    • This topic was modified 8 years, 1 month ago by wurgi.
Viewing 1 replies (of 1 total)
  • Plugin Author shazdeh

    (@shazdeh)

    is_product_category checks for product category archive pages, not to be confused with single product pages that are assigned to that category. If you want the latter, you could try something like:

    
    is_singular( 'product' ) && has_term( 'radius', 'product_cat' )
    

    Now that checks if visitor is on a product page that has the “radius” product category.

Viewing 1 replies (of 1 total)
  • The topic ‘Visibility Control for WooCommerce Products’ is closed to new replies.