jQuery 1.8 find event handlers

Use the data function as is done by jQuery internally.

On previous versions, you could call it like for other data :

obj.data('events');

In jQuery 1.8, this direct access was removed, so in recent versions you must call it like this :

$._data(obj[0], "events")

You can see it in action by opening the console in this fiddle : http://jsfiddle.net/8TpeP/2/

Leave a Comment