How to trace or debug all available javascript events

How can I trace all javascript events of a Webpage?

Is there a possibility to trace all events, even such without a handler attached?

Is there any tool out there, that can do this?


For example:

For a text input i can add an event handler for onblur and onchange.

If I (in the browser) change the value of the textfield and leave it, both eventhandlers are executed. Now I would like to know which other events I "have missed" (the ones which would have been executed if there was an eventhandler attached).


Can I get a list(on a given element) of all possible events I can attach an eventhandler?


Here is a list of Javascript events:

Here's a simple script to log all available events in the browser's console:

var ev = '',
    out = [];
for (ev in window) {
    if (/^on/.test(ev)) { 
        out[out.length] = ev;
console.log(out.join(', '));

Of course you'll get only the events of the browser you're currently using.

This is my favorite reference, it is updated more frequently than some of the other posts:

You can use FireBug Profiling Tool on FF and Web Developer Tool on IE8 or Developer Tools on WebKit


Just curious though, what do want to do with those events?

Need Your Help

UIWebView set initial zoom scale programmatically when loading an external website?

iphone ios objective-c uiwebview zoom

What I want to do is set the initial zoom scale [and in some cases, content offset, but that is less important] for an external website. But after the app initially sets the zoom and offset, the u...

Why is my iOS app not showing up in other apps' "Open in" dialog?

ios file-handling uti launch-services

I am trying to implement the registering process that allows my iOS app to show up in the "Open in" list of other applications (as described in Apple's Document Interaction Programming Topics). I w...