Wednesday, July 4, 2018

jQuery- jQuery click event not working after adding class

Since the class is added dynamically, you need to use event delegation to register the event handler

$(document).on('click', "a.tabclick", function() {
   alert('COMES');   
});

No comments:

Post a Comment