469,917 Members | 1,524 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,917 developers. It's quick & easy.

Related drop down lists all populated from database

5
Hi,

I have 3 related drop down menus all of which need to be populated from database.In the first list i populated the values from the database.
But i have trouble to proceed further.

The second has to be populated in based on the value chosen from the first dropdown and the third from the second.

I cant use submit button(so cant refresh page) and the second drop down has to be populated.So iam trying to collect the values into an array and use it in the VBscript(client side).This is also failing.

Can anyone please suggest how this can be done.

Thanks!!
John.
Oct 2 '07 #1
1 984
jhardman
3,406 Expert 2GB
John,

I have seen this done in two basic ways. The first is to submit the form using a javascript function every time a selection is made (this.form.submit()). The second is to have a lot of different versions of the second and third selects present and hidden on the page, then revealed when the appropriate selection is made. I have tried both and they work just fine (the second option is heavy on the javascript and the file is much larger. I tried it on an intranet system where I knew every user was using the same browser, I would be a little worried about my abilities to program this on the internet). Theoretically you could use ajax or advanced javascript to reconnect to the db after each selection and rewrite the other selects. This is kind of a variation on method 1, and I feel more confident using ASP, so I wouldn't try this if it was me, but do what you think you can do.

Jared
Oct 3 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

3 posts views Thread by Miguel Dias Moura | last post: by
13 posts views Thread by Leszek Taratuta | last post: by
reply views Thread by JohnZing | last post: by
3 posts views Thread by pmud | last post: by
7 posts views Thread by Miguel Dias Moura | last post: by
1 post views Thread by accyboy1981 | last post: by
reply views Thread by thebison | last post: by
1 post views Thread by Waqarahmed | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.