Show all category URL in wordpress

; 'orderby' =&gt; $orderby,<br ?> 'order' => $order,
'hide_empty' => $hide_empty,
'include' => $ids
);

$product_categories = get_terms( 'product_cat', $args );


$args = array(
'taxonomy' => "product_cat",
'number' => $number,
'orderby' => $orderby,
'order' => $order,
'hide_empty' => $hide_empty,
'include' => $ids,
'url' => $url
);
$product_categories = get_terms($args);
print_r($product_categories);
";


$category_link = get_category_link(964);


$i=1;
foreach($product_categories as $username) {
$items = $username->term_id;
echo $category_link = get_category_link($items);
echo "";
$i++;
}

Add a Comment

Your email address will not be published. Required fields are marked *