meta_key, meta_value not working
-
Hello ,
Meta Query is not working with latest Version 3.6.1 . It will display all the category available.
<?php
$args = array(
‘hide_empty’ => 0,
‘taxonomy’ => “product_cat”,
‘meta_key’ => “feature_category”,
‘meta_value’ => “1”
);
$query = get_terms($args);
?><?php print_r($query) ?>
And not able to use the :
function hpr_category_ordering($sort_args) {
$sort_args[‘meta_key’] = ‘feature_category’;
$sort_args[‘meta_value’] = ‘1’;
return $sort_args;
}add_filter(‘woocommerce_product_subcategories_args’, ‘hpr_category_ordering’);
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘meta_key, meta_value not working’ is closed to new replies.