I want to create a form with two drop-down lists (country and town), filled with options from two mysql tables. And I would like the second list (towns) to be populated with options depending on the value of selected option on the first list (country).
I know how to load the options with php and mysql into the countries list and I can link this to a second list that is populated with options from a javascript. There are conditionals in the script that updates the values of the second list. But I need some help with the mysql query for the second list. How can I start a second query when the page is already loaded?