php - Custom post type taxonomy image and link -
i have menu (figure 1)
when click onto 'external products', list of categories inside this, figure 2 shows.
what trying do, display of categories inside external products. have working, following code:
<div class="row"> <?php $terms = get_terms('externalproducts'); foreach ($terms $term) { echo "<div class='col-md-6'>"; $wpq = array ('taxonomy'=>'externalproducts','term'=>$term->slug); $myquery = new wp_query ($wpq); $article_count = $myquery->post_count; echo "<h4 id=\"".$term->slug."\">"; echo $term->name; echo "</h3>"; echo "<p>"; echo $term->description; echo "</p>"; echo "</div>"; } ?>
my question(s) are:
- how add image category, , display along title , description?
- how add link each category, display posts inside category.
if can fix this, amazing.
cheers.
for needs answer, found this:
http://zahlan.net/blog/2012/06/categories-images/
it worked treat, follow instructions!
Comments
Post a Comment