There are a bunch of people out there who are fed up with the lack of a console.log() equivalent in Internet Explorer. It shouldn't come as any surprise that I'm one of them.
It becomes significantly more painful, however, when you're trying to clean up JS code for the sake of performance. The usefulness of any metrics collected goes out the window once there's user activity involved. (Besides, clicking "OK" for all those alert boxes is a royal pain.)
(Hint to the IE8 team: Your product is still in beta. You must have a logging call somewhere. Publish it, please. Please. All the other browsers of note do.)
There are quite a few good console.log() equivalents out there, not the least of which are Faux Console and the Yahoo User Interface Logger Widget. For extremely light-weight applications, though, there was nothing that did just what I wanted, so I wrote one. You'll be depressed at how simple it is, and how easy it would have been for the IE team to have included this functionality at almost any point in IE's development cycle.
Ideally you'd drop this into an included script file, but it's more likely that you'll paste it into a <script> tag in the header of your HTML document.
The HTML that creates the DIV to contain the output:
A simple hello world script to log to it:
... and finally, the output: