Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Displaying Number of Items in Shopping Cart


demogoria

Recommended Posts

Hey, I have successfully modded my shopping cart to not dislay the items list (I wanted to keep it short) but I want to display the numerical value of the number of items that are in the cart.

 

I know I just have to mod the shopping_cart.php file, but I have no training in PHP code.

 

Can someone point me in the right direction here? :thumbsup:

 

Thanks!

Link to comment
Share on other sites

Here's a snippet of what I use:

  $ncart = $cart->count_contents();
<a href="<?php echo tep_href_link(FILENAME_SHOPPING_CART); ?>" class="headerNavigation"><?php echo HEADER_TITLE_CART_CONTENTS . ' (' . $ncart . ' item';
 if ($ncart != 1) echo 's'; ?>)</a>

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...