I’ve looked around on google and I cannot figure out to use for instance the dir() function within the web page I’m working on, I would like to have it spit out debug statements, as I’m used to doing with Firebug.
A clearer example
What I want is to do the following.
<script>
a=document.getElementById('gabber');
dir(a);
</script>
However doing this gets an undefined error.
console.dir works for me:
You can see all the functions available on the console like this:
(I get the following on Chrome 5.0.322.2:)