cat-parent without extra query. Closes #3355.
This commit is contained in:
parent
f8f3f8a660
commit
9f5f81c1aa
|
@ -64,6 +64,9 @@ class WC_Product_Cat_List_Walker extends Walker {
|
|||
if ( $args['current_category'] == $cat->term_id )
|
||||
$output .= ' current-cat';
|
||||
|
||||
if ( $args['has_children'] && $args['hierarchical'] )
|
||||
$output .= ' cat-parent';
|
||||
|
||||
if ( $args['current_category_ancestors'] && $args['current_category'] && in_array( $cat->term_id, $args['current_category_ancestors'] ) )
|
||||
$output .= ' current-cat-parent';
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ class WC_Widget_Product_Categories extends WC_Widget {
|
|||
$this->settings = array(
|
||||
'title' => array(
|
||||
'type' => 'text',
|
||||
'std' => __( 'Top Rated Products', 'woocommerce' ),
|
||||
'std' => __( 'Product Categories', 'woocommerce' ),
|
||||
'label' => __( 'Title', 'woocommerce' )
|
||||
),
|
||||
'orderby' => array(
|
||||
|
|
Loading…
Reference in New Issue