Zen Cart Logo
Forums / General Questions / 'Already in Cart' code sometimes works

'Already in Cart' code sometimes works

Locked

Views: 838

Results 1 to 3 of 3
This thread is locked. New replies are disabled.
27 Jan 2010, 10:13 PM
#1
g_force avatar

g_force

Zen Follower

Join Date:
Feb 2009
Posts:
354
Plugin Contributions:
0

'Already in Cart' code sometimes works

On the product info page the following code is tempermental so it doesn't always detect when the current product is already in the shopping cart:

$_SESSION['cart']->in_cart($_GET['products_id'])

.. anyone know why and how we can get it right every time?

_thanks

27 Jan 2010, 10:19 PM
#2
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: 'Already in Cart' code sometimes works

Do you have instances of DUPLICATED products? (ie: not LINKED products, but actual DUPLICATED products)?

These will be products that have identical information, but will have separate ID's

9 Feb 2010, 9:16 AM
#3
g_force avatar

g_force

Zen Follower

Join Date:
Feb 2009
Posts:
354
Plugin Contributions:
0

Re: 'Already in Cart' code sometimes works

sorry - no I don't .. they are all linked products > any significance??

_thanks