Drop Down Box Selection Populates Another Drop Down Box
Posted on 2009-04-15
The effect I want to create is really simple, however, doing it is not, at least for me.
I have a form on a page. When a selection in combo box 1 is made it populates combo box number 2 then 3 then 4.
Box 1 - Country
Box 2 - State
Box 3 - City
Box 4 - Zip Code
So for this example let assume I make the following choices:
Box 1: United States (All countries would be displayed in Box 1)
Box 2: Idaho (All 50 US States would have been available
Box 3: Boise (A list of cities that I wanted for Idaho would be here)
Box 4: 83705 (a List of available zip codes for Boise, ID, USA)
I know I have to supply the lists for each box, that is easy, I have the data.
#1. How can I do this?
#2. Is it possible to do this via a connection to a DB where each table in the DB contains information for a different field? That would be the best but I'll take whatever I can get help with.