wc_get_product_terms()WC 1.0

Wrapper used to get terms for a product.

Hooks from the function

Return

Array.

Usage

wc_get_product_terms( $product_id, $taxonomy, $args );
$product_id(int) (required)
Product ID.
$taxonomy(string) (required)
Taxonomy slug.
$args(array)
Query arguments.
Default: array()

wc_get_product_terms() code WC 8.7.0

function wc_get_product_terms( $product_id, $taxonomy, $args = array() ) {
	if ( ! taxonomy_exists( $taxonomy ) ) {
		return array();
	}

	return apply_filters( 'woocommerce_get_product_terms', _wc_get_cached_product_terms( $product_id, $taxonomy, $args ), $product_id, $taxonomy, $args );
}