jQuery Event - undelegate() Method
Example
Remove all event handlers added by the delegate() method from all elements:
$("body").undelegate();
Definition and Usage
The undelegate() method removes one or more event handlers added by the delegate() method.
Syntax
selector).undelegate(selector,event,function)
Parameters | Description |
---|---|
selector | Optional. Specifies the selector of the event handler to be removed. |
event | Optional. Specifies one or more event types of the handler function to be removed. |
function | Optional. Specifies the specific event handler function to be removed. |
More examples
- Remove event handlers added by delegate(), from a specific selector
- How to use the undelegate() method to remove all event handlers from a specified element.
- Remove event handlers of a specified event type added by delegate(), from a specified element
- How to use the undelegate() method to remove all event handlers of a specific event type from a specified element.
- Remove specific functions added by delegate()
- How to use the undelegate() method to remove a specific function for event handlers from a specific event type.