What does it mean by "Document" in javascript?

What is the significance of "Document" in javascript? is this an object ? i have see it has been several places !! is there any reason that it has been called as "document" ?
LVL 8
PeteEngineerAsked:
Who is Participating?
 
dmeerenCommented:
I use document.write to print something to the screen or alert box. So i think it is a command to write something. I never bothered to find out the exact meaning, i just ise it. Is i think a bit more, you can see a html page as an html document.
0
 
sniper038Commented:
yes it is the main object of a HTML page. It has some properties as well as other objects and events.
see http://www.comptechdoc.org/independent/web/cgi/javamanual/javadocument.html
and http://www.javascriptkit.com/jsref/document.shtml
for more info.
And regarding the naming, I think that it's because that javascript is copying some names from other languages like java. this might be the reason! anyhow it's not a big deal I think.
0
 
Olaf DoschkeSoftware DeveloperCommented:
Don't know why they called it document, but it's simply the root object of the html page the browser currently displays. The root object of a tree of object nodes representing the html elements and other document properties.

Bye, Olaf.
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
BadotzCommented:
Visit  http://www.sislands.com/coin70/week1/dom.htm  to get a better understanding of this.
0
 
BadotzCommented:
JavaScript Object Hierarchy
0
 
BadotzCommented:
The strong, silent type, eh?

No worries - glad to help.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.