is_product_category()
Is_product_category - Returns true when viewing a product category.
No Hooks.
Returns
true|false.
Usage
is_product_category( $term );
- $term(string)
- The term slug your checking for. Leave blank to return true on any.
Default:''
is_product_category() is product category code WC 10.8.1
function is_product_category( $term = '' ) {
return is_tax( 'product_cat', $term );
}