taxonomy parents
public text v1 · immutable<?php
global $conf;
foreach($node->taxonomy as $term) {
if ($term->vid == $conf['uc_catalog_vid']) {
$tree = taxonomy_get_parents_all($term->tid);
break;
}
}
if (isset($tree)) {
$tree = array_reverse($tree);
foreach($tree as $term) {
$links[] = l($term->name,drupal_get_path_alias(taxonomy_term_path($term)));
}
$links[] = "<span>{$node->title}</span>";
echo '<div class="product_collection_tree">' . implode(' / ',$links) . '</div>';
}
?>