Skip to main content | Turn off styling Default page style

Question & Answer index

Example of Dynamic Drop Down Lists

How can I make the items of one drop-down change based on the choice of a previous drop-down?

There are many ways to do this. In this example, I show how you can use jQuery's .getScript to fetch a javascript function from another webpage and run that function. The function that returns from the .getScript request changes based on the value passed into .getScript.

Select Parent Item
Select Child
Select Grandchild

Here is the jQuery for calling the webpage that returns the function that we want to run:

Here is an example of what the webpage returns: