views:

81

answers:

1

Hi I'd like to change the quantity in an AWS order. I've used the form below and that works fine for adding 1 item to the cart, but when I try to change it to a quantity of 2 it says there are no items in my cart. What am I doing wrong? Thanks.

<form method="GET" action="http://www.amazon.com/gp/aws/cart/add.html" id="Quantity">
    <input type="hidden" name="AWSAccessKeyId" value="Access Key ID" />
    <input type="hidden" name="AssociateTag" value="Associate Tag" />


    <?php
        echo "<input type='hidden' name='ASIN.1' value='".$itemid."'/>";
    ?>
    <input type="hidden" name="Quantity.1" value="1"/><br/>
    <input type="image" src="buynow.gif" value="Submit" alt="Submit">
</form>
A: 

You quantity is not being populated. I would place your items in an array and store them in session objects to preserve those items site-wide. Then, when you want to display your cart items, be sure to include your quantity directive in the tag; like so -

<input type="hidden" name="Quantity.1" value=". count($_SESSION['items']['id'] ."/>

Psypher