From Overview of JavaScript I -- Basic Web Scripting Language CPS616 Technologies of the Information Age -- Spring Semester 99. byGeoffrey C. Fox (Tom Scavo)
To list the properties of document: for ( var prop in document ) { with ( document ) { write( prop + " = " ); writeln( eval(prop), "<BR>"); } }
Recall that the with statement qualifies all object references within its scope