F A Q - M u l t i - i t e m   S u b m i s s i o n

This FAQ details how to have more than one item in a single form, allowing shoppers to choose many items on a single page, then add them all to the cart with a single click.

Q:
Is it possible to set up multiple purchase transactions on each page, without the necessity of visiting the cart site on each one? We will be selling quite a number of small items, and we'd like our customers to be able to select a variety of them without constantly having to press the 'Continue Shopping' button on your server.

A:
Yes, we support that. The html coding is slightly different, but not difficult at all. Since we will have more than one "item" inside a single form, calling them all "item" would result in data overruns. So instead, call each separate item "item_something", with the something being a unique string.

All options work with this method also, with similar name changes. See the page: http://www.cartserver.com/sc/bread.html for an example followed by a detailed explanation on how to do it.

Q:
My multi-item submision doesn't put all my selected products into the cart. Why?

A:
The most common reasons are:

1) Closing the form with </form> prematurely, thus excluding items on the other side of the tag.

2) Not using proper multi-item naming conventions such as:
item_abc
op2_abc

Erroneously putting op2_abc INSIDE the item_abc variable:
<!-- bad code -->
<input type=hidden name=item_abc value="a-1358^abc^descrip^2.00^op2_abc">
<input type=text name=op2_abc>Enter Quantity

The above LOOKS right, but it is not. Since op2 for that item is named op2_abc, but since all multi-items are parsed down to a bunch of single items, you use the simple name op2 internally in the item variable.

Instead, use:
<!-- good code -->
<input type=hidden name=item_abc value="a-1358^abc^descrip^2.00^op2">
<input type=text name=op2_abc>Enter Quantity

Q:
How can I get one op variable to set the quantity for every "item" in the multi-item form?

A:
Use the "special" op variable
op99. op99 is sort of a global op variable, and will apply as quantity for every item variable which names it in its quantity field.

<input type=hidden name=item_abc value="a-1358^abc^descrip^2.00^op99">
<input type=hidden name=item_xyz value="a-1358^xyz^descrip^2.00^op99">
<input type=text name=op99>Enter Quantity

The above would add BOTH items to the cart in the quantity the shopper enters.

Q:
I need to choose a color ONE time for all items in the form. Is there an op variable that will apply to the description for all items in a single form?

A:
Use the "special" op variable
op98, which will have its value added to the description of all item variables in the form. It can save you a lot of bother in certain situations.

Americart FAQ main page