populate select box jquery, php and chosen plugin -


I am using the plugin, php, and jquery selected to populate a selection box with data from the database .

After clicking on the user selection box:

  $ ("# mabranche"). Next (). Dump ('click', function () {// get data from database}}  

Everything is recovering, the data is shown:

But when I get an item (after debugging the code) , Then the above function is called again.

I also tried to use

  $ ('# mabranche') Live. ('Focus', function () {// get data from database}}  

but it works the same as for other examples (even if I select an item, the selection box loses no focus and the function calls again)

< P> Is there a way to manage this problem?


Comments