Support » Plugins and Hacks » WooCommerce » [Plugin: WooCommerce – excelling eCommerce] is_product_category vs. in_product_category

  • Resolved sime0n

    (@sime0n)


    Hey,

    I’m extending a theme to use a different Nivo slider for each category / subcategory. is_product_category works well for the top level category but products inside that category are being missed since technically they aren’t the category itself (in vs. is).

    Is there a WooCommerce function for specifying products in a category, something like:

    if ( in_product_category( ‘#’ ) ) {
    echo do_something();
    }

    I checked out the conditionals page and searched through the WooCommerce docs but didn’t find anything.

    Is there currently a way to display elements in certain product categories and not others? TIA

    http://wordpress.org/extend/plugins/woocommerce/

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[Plugin: WooCommerce – excelling eCommerce] is_product_category vs. in_product_category’ is closed to new replies.