Drop Down menu

G

Gerry O

I have what seems like a simple question, but I just can't figure it out.
This is for an online store.
I have a drop down menu. The text in the menu has size and price. When
submitted, it submits price. Is there a way to get the drop down to submit
two variables? Price and size?
 
B

brucie

I have a drop down menu. The text in the menu has size and price. When
submitted, it submits price. Is there a way to get the drop down to submit
two variables? Price and size?

easily but you shouldn't. just submit the size and the script server
side should match the price with the size. don't use the prices visitors
see or that are in the markup, they may change them.
 
L

Leif K-Brooks

Gerry said:
This is for an online store.
I have a drop down menu. The text in the menu has size and price. When
submitted, it submits price. Is there a way to get the drop down to submit
two variables? Price and size?

<option value="33 10">$33 10 inch</option>

And have your script use the first space-seperated value as price and
the second as length, but that's terribly insecure. You should have an
ID for each size/price combo and have the script know the sizes and
prices, otherwise I can pay nothing.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,014
Latest member
BiancaFix3

Latest Threads

Top