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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dropdown determines results in next dropdown 1

Status
Not open for further replies.

skicamel

Programmer
Dec 24, 2001
126
US
Not sure which forum to post this to, feel free to send me elsewhere if need be...

Is it possible, on one page, to have two dropdown boxes... the first drop down to choose a database, then the second dropdown would query that particular database for the values to populate it?

Ex.

Dropdown 1: database1 (value = Database1)
database2 (value = Database2)
database3 (value = Database3)

Dropdown 2: Staff Member (value = unique ID based on which database chosen in first dropdown)

I'd imagine there is some javascript or some similar On_____ type method to hold off querying until a db is selected... Just not sure where to go...

Don't mind doing my own homework, but any pointers would be appreciated.

Thanks again all.
 
You will need to add event onchange in your first dropdown1,
in this event onchange reload the page or submit the form, to pass value chosen in dropdown 1.
For forming dropdown 2 use this passed value of dropdown 1.

Main idea is that after changing value of dropdown 1 you will need to reload page and form dropdown 2 depending on passed value of dropdown 1.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top