For variuous reasons, I am using taxonomy terms for authors. Each blog node has a term reference field - field_authors - which lists one or more authors. What I would like to do is display the term description for each author listed in the page. My searches online got me the following code which I placed in node--blog.tpl.php just after the title of the blog post.
<?php
$vid = taxonomy_vocabulary_machine_name_load("authors")->vid;
$terms = taxonomy_get_tree($vid, 0, null, true);
$term_count = count($terms);
for ($i = 0; $i < $term_count; $i++) {
$name = $terms[$i]->name;
$id = $terms[$i]->tid;
$description = $terms[$i]->description;
?>
<div id="<?php print $id; ?>" class="taxonomy-description">
<?php print $description; ?>
</div>
<?php } ?>
As you can probably tell, it prints all taxonomy term description for the vocabulary 'authors'. I would like to show just the descriptions for the terms(authors) listed in that page.
It also occurs to me that there maybe better ways of achieving this. So any better suggestions would be most appreciated.