Dynamic Select with query

0

I want to make a dynamic form like this: link

I'm having difficulty linking mysql, php, and javascript to the following extent: -The first select the options values are generated by a query (Select * from Continent)

- As selected Continent automatically generates Country select options by querying (Select * from Country where id_continent="id")

    
asked by anonymous 23.02.2017 / 18:23

1 answer

1

You can use a .getJSON () in your javascript and retrigger a list of country options ...

$.getJSON("SelecionarPaises.php", data : idcontinente).done(function (paises) {
// vai receber uma lista de paises aqui, ai pode adicionar onde quiser
});
    
24.02.2017 / 15:10