Adding custom taxonomy description to top of taxonomy displaying
-
Hi,
So for example if I had website.com/genres/rock I’d want to show the description for the Rock tag in the Genres custom taxonomy.After a bit of searching around i added this into my taxonomy.php:
<div id="description"> <?php $termDiscription = term_description( '', get_query_var( 'genre' ) ); if($termDiscription != '') : ?> <div class="tag-desc"><?php echo $termDiscription; ?></div> <?php endif; ?> </div>
However it doens’t seem to work, does anyone have any ideas?
Also i have multiple custom taxonomies, so is there a variable that has info of the taxonomy you are viewing? so i could replace get_query_var(‘genre’) to get_query_var($taxonomy), otherwise i’ll have to have taxonomy-genre.php, taxonomy-bob.php etc!Thanks.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Adding custom taxonomy description to top of taxonomy displaying’ is closed to new replies.