You can visit the PHP drop down list tutorial to learn how dynamic drop down lists can be developed by server side scripts. You can also see similar server side script in ASP using VBScript where second drop down is managed.
Read how Ajax is used to manage two drop down lists in PHP section.
Demo of the client side drop down script
With this let us go to the demo of the script. Here we have three elements ( options ) in the first drop down list category ( fruits , games and scripts ) and each has three options has three sub options ( sub category ).
Now let us study how this works and the script for this demo in our next section. You can download the code of this tutorial at the end.
Learn how the same drop down list is developed by taking data from Mysql table
Found anything wrong or wants to improve the code by adding more features? Post your short comment here or use the Forum
|Great, script, I want to use this but have two forms (exactly the same) on one html page and cannot implement this script for both - do you know how I could do that?|
|The code does not work if allowing user to make multiple selections (i.e. multiple="multiple"). Please add update for this in your tutorial. Thank you!|
|how to integrate ajax with multiple selection with dropdown list.is there any solution for that|
your help will be appreciated
|Can you tell me how to encode categorie and subcategorie values to display in utf-8 format?|
|I need to have multiple instances of the Double drop down list box on my form (I need to use it three time). I have been unable to figure this out, can anyone offer assistance?|
|My programming experience is minimal, but I was able to follow this tutorial relatively easily and implement it (dynamic population of second list box...) within a couple of hours, and now I´m very happy - thank you!|
|hai this nice then display the coding all of u used it|