Each option of the dropdown field contains two data values: quantity and price. I'm selling some products online and I'd like to have different prices based on the quantity of the product order.
Below is the code that I was thinking, though it's not functional... just wanted you to understand what I'm looking for!
<form name="form1" action="http://www.domain.com/cgi-bin/submit.pl" method="post">
<option value="1/10">1 piece ($10 each)
<option value="2/9">2 pieces ($9 each)
<option value="3/8">3 pieces ($8 each)
<option value="4/7">4 pieces ($7 each)
<option value="5/6">5 pieces ($6 each)
<input type="hidden" name="quantity" value="--QUANTITY SELECTED ABOVE--">
<input type="hidden" name="price" value="--PRICE ASSOCIATED WITH THE SELECTED QUANTITY--">
<input type="submit" value="Submit">
Basically the user selects the desired quantity, and after his submission the form will pass me the quantity and the price from the dropdown field in TWO SEPARATE hidden variables.
I have several such products on a single HTML page, so the solution should be capable of working with multiple product forms on the same page. It's also important that I have only ONE dropdown field, plus the submission button. Nothing else really.