July 2011
Intermediate to advanced
276 pages
5h 11m
English
Keep in mind that mybutton is the trigger for our actions in this recipe.
<input type="button" id="mybutton" value="Greet Me!"/>
Continuing from the previous recipe where we have associated both click and mouseover actions to a triggering INPUT button, we prepare to remove some, but not all, events.
$('mybutton').removeEvents('mouseover');
The object function Element.removeEvents() when used without any optional arguments will remove all events bound to an element. Passing in the single argument "mouseover" causes all events bound to that event action to be removed. This allows for the onClick() action previously bound to continue to function while preventing the ...