Thursday, December 24, 2015

jQuery click button events firing multiple times




I  has jquery click event
   $('.addRow_section').live('click',  function(){

When the button is clicked, it is fired multiple times.
This is due to that  the particular event is bound multiple times to the same element.
To fix this add die function:
             $('.addRow_section').die("click");
              $('.addRow_section').live('click',  function(){

Reference:
http://stackoverflow.com/questions/14969960/jquery-click-events-firing-multiple-times

No comments:

Post a Comment