Example #1
0
	<?php 
    if (!empty($item->link)) {
        ?>
	<a class="pathway" href="<?php 
        echo $item->link;
        ?>
"><?php 
        echo $item->name;
        ?>
</a>
	<?php 
    } else {
        ?>
	<?php 
        echo $item->name;
        ?>
	<?php 
    }
    ?>

<?php 
    if ($catcount < $count || $item->link != '') {
        // This prints the separator image (uses the one from the template if available!)
        // Cat1 * Cat2 * ...
        echo vmCommonHTML::pathway_separator();
    }
    $catcount++;
}
if (isset($return_link) && !empty($return_link)) {
    echo $return_link;
}
Example #2
0
$tpl->set('next_product_url', $next_product_url);
$tpl->set('previous_product', $previous_product);
$tpl->set('previous_product_url', $previous_product_url);
$parent_id_link = $db_product->f("product_parent_id");
$return_link = "";
if ($parent_id_link != 0) {
    $q = "SELECT product_name FROM #__{vm}_product WHERE product_id = '{$product_parent_id}' LIMIT 0,1";
    $db->query($q);
    $db->next_record();
    $product_parent_name = $db->f("product_name");
    $return_link = "&nbsp;<a class=\"pathway\" href=\"";
    $return_link .= $sess->url($_SERVER['PHP_SELF'] . "?page=shop.product_details&product_id={$parent_id_link}");
    $return_link .= "\">";
    $return_link .= $product_parent_name;
    $return_link .= "</a>";
    $return_link .= " " . vmCommonHTML::pathway_separator() . " ";
}
$tpl->set('return_link', $return_link);
// Create the pathway for our template
$navigation_pathway = $tpl->fetch('common/pathway.tpl.php');
if ($ps_product_category->has_childs($category_id)) {
    $category_childs = $ps_product_category->get_child_list($category_id);
    $tpl->set('categories', $category_childs);
    $navigation_childlist = $tpl->fetch('common/categoryChildlist.tpl.php');
}
// Set Dynamic Page Title
if (function_exists('mb_substr')) {
    $page_title = mb_substr($product_name, 0, 64, vmGetCharset());
} else {
    $page_title = substr($product_name, 0, 64);
}