News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Show categories as attributes in product view?

Started by be, October 26, 2012, 00:13:14 AM

Previous topic - Next topic

be

Hi,
how can I show the multiple categories from one product in the productview?
Actally I use $this->category->category_name;,
but with this I got only displayed the category in which I´m actually be and not all the categories where the product is set in the backend under
"Product Information".

Propably it could be possible to solve this with a direct db-query like this:

$dbcat = JFactory::getDBO();
$dbcat->setQuery("SELECT custom_value FROM #__virtuemart_product_customfields WHERE virtuemart_product_id=".$product->virtuemart_product_id." and virtuemart_custom_id=17 ;"); 
$dbcat->query();
$resultcat = $db2->loadResult();

But my programingskills are to small to get the db-query for the multiple categories work, also because the Information is stored in several mysql-tables.

BR