I have an input type="image"
. This acts like the cell notes in Microsoft Excel. If someone enters a number into the text box that this input-image
is paired with, I setup an event handler for the input-image
. Then when the user clicks the image
, they get a little popup to add some notes to the data.
My problem is that when a user enters a zero into the text box, I need to disable the input-image
's event handler. I have tried the following, but to no avail.
$('#myimage').click(function { return false; });
转载于:https://stackoverflow.com/questions/209029/best-way-to-remove-an-event-handler-in-jquery