Do something conditinally on node.tpl.php depending on if the node is tagged with certain taxonomy vocabulary I found how to do this if the node is tagged with certain terms here.
But what I would like to do is to do something conditionally in node.tpl.php only if the node is tagged with a certain vocabulary.

For example, I have a vocabulary called "Color" with terms "Red" "Blue" "Yellow". I would like to display the text "It has color" only if the node is tagged with at least one of those terms. Otherwise print nothing.

How can I do this in  node.tpl.php ?
Each taxonomy term in a node also gives you the vocabulary id that it belongs to.  So you could look through the terms to see if one matches the vocabulary id of your "Color" vocabulary and then display "It has color" when found.

An easy way to do this would be to use a loop:

&lt;?php foreach ($node-&gt;taxonomy as $key =&gt; $term): ?&gt;
  // Say the vocabulary id of "Color" is 10.
  &lt;?php if ($term-&gt;vid == 10): ?&gt;
    &lt;div&gt;
      &lt;?php print views_embed_view('my-views', 'default', $args); ?&gt;
    &lt;/div&gt;
    // etc
    &lt;?php break; ?&gt;
  &lt;?php endif; ?&gt;
&lt;?php endforeach; ?&gt;


For reference, to access the vocabulary id of a single term:

$node-&gt;taxonomy[TERM_ID]-&gt;vid;


Where TERM_ID is the id of the taxonomy term.