I use Bootstrap
and jQuery
. I have three buttons, each with an icon in it. When I bind an click
-event to a button, it works when I cli
Update your css with the following. I'm assuming you don't need mouse events on your icon.
.icon-eye-open {
pointer-events:none;
}
MDN Information regarding pointer-events
Use the following syntax for .on()
$(document).on('click','btn_change_status', function(e) {
//write your code here
});
You need a different syntax, as per the documentation:
$('body').on('click', 'button.btn_change_status', function(e) {
alert(e.target.id);
return false;
});