WC_Brands::brand_description
Displays brand description.
Метод класса: WC_Brands{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
$WC_Brands = new WC_Brands(); $WC_Brands->brand_description();
Код WC_Brands::brand_description() WC Brands::brand description WC 10.3.4
public function brand_description() {
if ( ! is_tax( 'product_brand' ) ) {
return;
}
if ( ! get_query_var( 'term' ) ) {
return;
}
$thumbnail = '';
$term = get_term_by( 'slug', get_query_var( 'term' ), 'product_brand' );
$thumbnail = wc_get_brand_thumbnail_url( $term->term_id, 'full' );
wc_get_template(
'brand-description.php',
array(
'thumbnail' => $thumbnail,
),
'woocommerce',
WC()->plugin_path() . '/templates/brands/'
);
}