Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

Product Category

// WP_Query arguments
$args = array(
	'post_type'              => array( 'product' ),
	'post_status'            => array( 'published' ),
	'tax_query'              => array(
		'relation' => 'AND',
		array(
			'taxonomy'         => 'taxonomy_var',
			'operator'         => 'IN',
			'include_children' => false,
		),
	),
);

// The Query
$query = new WP_Query( $args );