Welcome Guest, Not a member yet? Register   Sign In
Shopping Cart
#12

[eluser]beaudierman[/eluser]
The reason it's returning 1 is because you're using the PHP count function, which isn't working because of the multi-dimensional array that is being put in it. The cart class' total_items function returns an integer already so the count function isn't needed.

This should return 6 if you have 6 items in your cart:

Code:
<?php echo $this->cart->total_items(); ?>


Messages In This Thread
Shopping Cart - by El Forum - 06-06-2012, 05:15 AM
Shopping Cart - by El Forum - 06-06-2012, 05:19 AM
Shopping Cart - by El Forum - 06-06-2012, 05:20 AM
Shopping Cart - by El Forum - 06-06-2012, 05:26 AM
Shopping Cart - by El Forum - 06-06-2012, 05:31 AM
Shopping Cart - by El Forum - 06-06-2012, 05:34 AM
Shopping Cart - by El Forum - 06-06-2012, 05:39 AM
Shopping Cart - by El Forum - 06-06-2012, 07:41 AM
Shopping Cart - by El Forum - 06-06-2012, 08:10 AM
Shopping Cart - by El Forum - 06-06-2012, 11:00 AM
Shopping Cart - by El Forum - 06-06-2012, 01:44 PM
Shopping Cart - by El Forum - 06-06-2012, 01:59 PM
Shopping Cart - by El Forum - 06-06-2012, 02:09 PM
Shopping Cart - by El Forum - 06-06-2012, 02:12 PM



Theme © iAndrew 2016 - Forum software by © MyBB