Tutorial: Creating Dependent Dropdown - How to add cities?

Hi everybody,

I read about creating dependent dropdowns in the tutorial section and have a question about it.

Where and how do I add the cities? :)

Somehow I didn’t get this part…

Thanks a lot in advance! :)


I found some separate thread with same issue. It may help you.


Thank you for your reply.

Do you know of a way to retrieve the data for the second dropdown from simply an array?

Would it be possible to get the data from either $cities_us or $cities_fr depending on which country is selected in the first dropdown?!

The arrays would look like this:

$cities_us = array('los angeles', 'san francisco');

$cities_fr = array('paris', 'carcassonne');