Fix for Code

  1. $name = '';
  2. foreach ($node->taxonomy as $item) {
  3.   if ($item->vid == 10) {
  4.     $name = check_plain($item->name);
  5.     break;
  6.   }
  7. }

Submit Fix

Any tags you'd like to associate with your code, delimitered by commas (example: Views, CCK, Module, etc).
Select the syntax highlighting mode to use.