When using a FORM to reference the engine, the HTML is slightly different. Instead of embedding the function, Vendor ID and tokens on the URL command line, they are listed as hidden fields inside the form.
Take a look at this example:
In the above example, we've specified two distinct products with different ID numbers for the glass and plastic versions of the Bar-B-Que sauce. Also note that we've made the "iqty" field user-selectable so that a specific quantity can be selected at the time of adding the item to the basket. Another change is that with a FORM, you can have the user add more than one item at a time with a single selection.
Here is what the HTML looks like:
Be sure to note the order in which the fields are specified. This is important! First specify the Vendor ID (c_xxx with a value of "1"), then the function, followed by information on each product in the form in the following order:
Now, let's get fancy with some extra features. Instead of having two different products, let's create one line-item, with a pull-down menu where the user can specify the "style" (either glass or plastic):
Now let's get even fancier using TABLES and more products. Let's say that Bob is doing so well, he needs to introduce more products. So he comes up with three flavors (Original, Hickory, and Extra Hot) and three sizes (12oz, 24oz, and 44oz bottles). Let's see how we can make a simple tabular form to handle this:
As you can see, there is a lot of flexibility afforded in using FORMs - just take your time and make sure all the data is properly specified.
NOTE that the hidden form fields can be placed anywhere inside of the table, but they should remain listed in the appropriate order. It is recommended that if you use tables, insert most of the hidden fields in the first table column - it won't have any affect on the formatting. If you put hidden fields outside of the table rows or columns, some browsers will not properly interpret these commands and leave blank space at the end of the table.