ok the following is what I added to product.php
PHP Code:
// TEST ADDITION //
$product_cat = func_query("SELECT category FROM $sql_tbl[categories] WHERE categoryid IN (SELECT categoryid FROM $sql_tbl[products_categories] WHERE productid ='$productid')");
if (!empty($product_cat)) {
foreach ($product_cat as $c => $d) {
$explode_cats[] = $d['category'];
}
$smarty->assign("explode_cats", $explode_cats);
}
// END TEST ADDITION //
And in product.tpl I added:
------------------------------
<div>
{foreach from=$explode_cats item=c}
<a href="search.php?mode=search&including=any&categor yid=1" title="{$c}">{$c}</a> |
{/foreach}
</div>
How can I pass the category id's to product.tpl in above so each href is correct for each categoryid? I have the categories passing correctly, I just can't figure out how to get the id's.
Thanks
