Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Forms: Dropdown box alters next dropdown box

Status
Not open for further replies.

qtluvsjc

Technical User
Apr 27, 2007
18
US
This is what I'm trying to do on my form:

<dropdown box 1 "Item"> <Dropdown box 2 "Color"> <Dropdown box 3 "Size">

- Item would be a list of items we are selling.

- Color would be choosing from up to 4 different colors. Not all of these colors are available for every item, so depending on what item was selected, the "color" dropdown box would be updated with choices that are available for that specific item.

- Size would be the same idea as color, but based on item as well. This also varies depending on which item is selected.

Anyone have a tutorial on how to do this, or some code I could use as a start? Any help would be appreciated!
Thanks,
Tiffany
 
Hi

Your question is off-topic, this can not be done with HTML and/or CSS.

Decide if you want to solve it with client-side or server-side script, then post your question in the forum related to the chosen language/technology. ( Your decision should be influenced by the amount of data. )

( In case you choose to do it client-side, see Dan's FAQ before re-posting your question : faq216-6294 . )

Feherke.
 
I agree, this would require some type of programming language. Personally if the drop downs aren't too long, like maybe up to 10 items each, I would do it with JS. If your drop downs are longer than that, I would consider Ajax to query the server for the options and dynamically build the drop downs as necessary.

----------------------------------
Phil AKA Vacunita
----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.

Behind the Web, Tips and Tricks for Web Development.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top