Forums / Templates, Stylesheets, Page Layout / Adding category to shopping cart

Adding category to shopping cart

Views: 4,241

Results 1 to 3 of 3
2 Jul 2013, 8:26 AM
#1
dannyvarley avatar

dannyvarley

Zen Follower

Join Date:
Dec 2011
Posts:
287
Plugin Contributions:
0

Adding category to shopping cart

Hi Everyone,

I'm looking to add the category of the product next to the name on the shopping cart,

I imagine you will be changing the includes/templates/yourtemp/templates/tpl_shopping_cart_default.php
But im not sure what to put.

Danny

2 Jul 2013, 2:08 PM
#2
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Adding category to shopping cart

You could customize the file:
/includes/templates/template_default/templates/tpl_shopping_cart_default.php

using your templates and overrides with the code in RED:

<a href="<?php echo $product['linkProductsName']; ?>"><span id="cartImage" class="back"><?php echo $product['productsImage']; ?></span><span id="cartProdTitle"><?php echo [B]zen_get_categories_name_from_product($product['id']) . '<br />' . [/B]$product['productsName'] . '<span class="alert bold">' . $product['flagStockCheck'] . '</span>'; ?></span></a>

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

3 Jul 2013, 1:17 PM
#3
dannyvarley avatar

dannyvarley

Zen Follower

Join Date:
Dec 2011
Posts:
287
Plugin Contributions:
0

Re: Adding category to shopping cart

Exactly What I was looking for,

Thanks!