1st off -- remove the single quotes;
$shoppingcart = array("buy"=>$buy, "quantity"=>$quantity);
2nd. I would do this:
$shoppingcart[] = array("buy"=>$buy, "quantity"=>$quantity);
This is the same as array_push, but it's a little easier. $shoppingcart[0]
now contains your array. If you did it
Hey again all, right I've tried using an associative array for my shopping
cart and I've encountered two problems - so far. The first problem is that
I can't only add one item to the cart and the second problem is that when
viewing the cart it shows two items in it. I think this is because there