Hi! I have a problem.
I want to disable links in a specified class. Like this: $(".disabled").click( function() { return false; }); It works fine if the class exists before, but if I add the class to an element, not works!! $(document).ready(function() { $(".disabled").click( function() { return false; }); $(".noClick").click( function() { $(this).addClass("disabled"); }); }); The HTML: <a href="#" class="noClick">Click!</a> (This is an example, I know that isn't logic)