Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

Revision 804565 of DOM

  • Revision slug: Glossary/DOM
  • Revision title: DOM
  • Revision id: 804565
  • Created:
  • Creator: klez
  • Is current revision? No
  • Comment capitalized acronym expansion

Revision Content

The DOM (Document Object Model) is an {{glossary("API")}} that represents and interacts with any {{glossary("HTML")}} or {{glossary("XML")}} document. The DOM is a document model loaded in the {{glossary("browser")}} and representing the document as a node tree, where each node represents part of the document (e.g. an {{Glossary("element")}}, text string, or comment).

The DOM is one of the most-used {{Glossary("API")}}s on the {{glossary("World Wide Web","Web")}} because it allows code running in a browser to access and interact with every node in the document.  Nodes can be created, moved and changed. Event listeners can be added to nodes and triggered on occurrence of a given event.

DOM was not originally specified--it came about when browsers began implementing {{Glossary("JavaScript")}}. This legacy DOM is sometimes called DOM 0. Today, the W3C leads DOM specification, and the DOM Working Group is currently preparing version 4.

Learn more

General Knowledge

Technical information

Revision Source

<p>The DOM (Document Object Model) is an {{glossary("API")}} that represents and&nbsp;interacts with any {{glossary("HTML")}} or {{glossary("XML")}}&nbsp;document. The <span style="font-size:14px; line-height:1.5">DOM </span>is a document model loaded in the {{glossary("browser")}} and representing the document as a node tree,&nbsp;<span style="font-size:14px; line-height:1.5">where each node represents part of the&nbsp;document (e.g. an {{Glossary("element")}}, text string, or comment).</span></p>

<p><span style="font-size:14px; line-height:1.5">The DOM is one of the most-used {{Glossary("API")}}s on the {{glossary("World Wide Web","Web")}} because it </span>allows code running in a browser to access and interact with every node in the document.&nbsp;<span style="font-size:14px; line-height:1.5"> Nodes can be created, moved and changed. Event listeners can be added to nodes and triggered on occurrence of a given event.</span></p>

<p><span style="font-size:14px; line-height:1.5">DOM was not originally specified--it came about when browsers began implementing {{Glossary("JavaScript")}}. This legacy DOM is sometimes called&nbsp;DOM 0. Today, the W3C leads DOM specification, and the DOM Working Group is currently preparing version 4.</span></p>

<h2 id="Learn_more">Learn more</h2>

<h3 id="General_Knowledge">General Knowledge</h3>

<ul>
 <li><a href="https://en.wikipedia.org/wiki/Document_Object_Model" rel="external">The Document Object Model on Wikipedia</a></li>
</ul>

<h3 id="Technical_information">Technical information</h3>

<ul>
 <li><a href="/en-US/docs/DOM">The DOM documentation on MDN</a></li>
 <li><a href="https://www.w3.org/DOM/DOMTR" rel="external">The various DOM specifications at W3C</a></li>
</ul>
Revert to this revision