This function removes an event from an object.

Parameters:

  • obj – the object or element from which the event will be removed.
  • eventName – eventName to remove from the object.
  • func – the event handler function.

Example:

The example below assumes that the greeting() function has previously been added as an event to the myButton object.

removeEvent(myButton, "click", greeting);
  • No labels