Re: Can anyone help please.
| From: | Tom Rogers | Date: | Sun, 27 Oct 2002 16:01:56 +0000 |
| Subject: | Re: Can anyone help please. | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-121598@lists.php.net to get a copy of this message | ||
Hi,
Monday, October 28, 2002, 1:44:37 AM, you wrote:
SJ> I have two test carts online at the moment.
SJ> This one works fine:
SJ> http://www.violasystems.com/shop/
SJ> this one is the one I want to get working
SJ> http://www.violasystems.com/shop_testing/
SJ> The code for the first shop basically increments the cart by one when the
SJ> submit button is added using the commented out code.
SJ> $qty = $formqty;
SJ> if($cart[$new])
SJ> //$cart[$new]++;
SJ> $cart[$new] = $cart[$new] + $qty;
SJ> else
SJ> $cart[$new] = 1;
SJ> $total_price = calculate_price($cart);
SJ> $items = calculate_items($cart);
SJ> I have added the rest (taking a variable from the form $formqty and adding
SJ> it to the cart)
SJ> Can anyone see why doesn't this work?
You seem to have other problems than the code here ..
Warning: Invalid argument supplied for foreach() in /www/u1255/shop_testing/show_cart.php on line 30
--
regards,
Tom