VirtueMart Forum

VirtueMart 2 + 3 => Templating & Layouts => Topic started by: mediax on May 08, 2018, 11:27:37 am

Title: Include Category Name in Cart.php
Post by: mediax on May 08, 2018, 11:27:37 am
Hi VM,

I am running an older version of VM3 - VirtueMart 3.0.12 (Forgive this for now please.)

How do I add the Category Name of the Product - Before the product title on the cart.php page. I found an old example for VM 1.1, but nothing for more current versions of VM. Any help or guidance would be appreciated.

OLD EXAMPLE: http://forum.virtuemart.net/index.php?topic=49850.0
Title: Re: Include Category Name in Cart.php
Post by: Studio 42 on May 08, 2018, 22:09:10 pm
If you get item in  \components\com_virtuemart\views\cart\tmpl\default_pricelist.php ? Or check same file on your templates/YOURTEMPLATE\html\com_virtuemart\default_pricelist.php
<?php echo $prow->category_name ?>
If it not work, you have to get product from product model.
Title: Re: Include Category Name in Cart.php
Post by: mediax on May 08, 2018, 22:35:00 pm
That worked perfectly, thank you !