Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

jquery 1.4 Live behaviour on .each?

Does jQuery allow us to use .each loops for live elements?

I'm creating radio buttons on the fly and need to loop over all of them, but the .each loop doesn't seem to work on live elements.

If jquery is not supporting this kind of live looping, is there any other way to accomplish this?

like image 217
Jorre Avatar asked Feb 14 '10 18:02

Jorre


1 Answers

live() only works for event binding. The only thing that comes to my mind is to put all code in a function an execute it again after you inserted the elements.

like image 87
Felix Kling Avatar answered Sep 26 '22 02:09

Felix Kling