How to get taxonomy term to show under each image, which is already defined in each Album. I no need to add the same taxonomy under each picture.
I added some code in tpl file but it give me not what I need

 <?php print $content; ?>
  <div class="node node-type-node-gallery-gallery">																																															
			<div class="field field-type-text field-field-author-name">
			<?  // print_r ($node->taxonomy); 
				//foreach ($node->taxonomy as $term)
				//	{
				//	print $term->name . "&nbsp;";
				//	}
			?>
			<div class="field-label">
            <div class="field-items"> 
				<div class="field-item odd"> 
			<?  // print_r ($node->taxonomy); 
				//foreach ($node->taxonomy as $term)
				//	{
				//	print $term->name . "&nbsp;";
				//	}
			?>      </div> 

Comments

scroogie’s picture

That could would only work if the image itself would be added to the taxonomy.

If you want to use the taxonomy of the gallery, you will have to retrieve the gallery node first:

 $gallery = node_load($node->gid);

Then you can use

 foreach ($gallery->taxonomy as $term) {
   print '<a href="/taxonomy/term/' . $term->tid . '">' . $term->name . '</a>';
 }

or whatever you want to do.

justintime’s picture

Or you could use Node Gallery Taxonomy to keep things in sync between the gallery and the image.

zengenuity’s picture

Correct link to Node Gallery Taxonomy.

zengenuity’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.