Thursday, October 20, 2005

JavaScript Execution from IE Address Bar

I never knew of this capability until today:

You can execute JavaScript from Internet Explorer's address bar, and it will use objects on the currently loaded page.

For instance, load a page into IE (perhaps the one you're currently reading???), and then type this into the address bar:

javascript:alert(document.all.length);

or

javascript:alert(document.body.innerHTML)