DOM

The Document Object Model (DOM) is an Application Programming Interface (API) to access and modify the content, structure, and style of XML, HTML, and related documents

TAGS: Cyber Tech, Programming, Standards, TECH

The Document Object Model (DOM) is an Application Programming Interface (API) to access and modify the content, structure, and style of XML, HTML, and related documents. Various programming languages can utilize the DOM. [The alternative to a DOM tree-based API is an event-based API such as SAX.] An application (such as a browser) that implements the DOM (by implementing the DOM interfaces) will allow programmers to use the DOM interfaces within a programming language such as JavaScript, VBScript, etc., to have near total control over all elements in documents. Objects in the DOM have properties, methods, events, sub-objects, and collections. In one sense, DOM is to a document as ADO is to a database.

Before the W3C standardized DOM 1.0, browsers (MSIE 3 & NS 3) manipulated HTML and the browser itself via what was called DHTML (Dynamic HTML or DOM HTML). Since the W3C standardized DOM 1.0, 2.0, etc., each version of each browser supports subsets and supersets of different the versions of the W3C DOM. These proprietary browser DOMs that cover documents and the browser may still rightly called DHTML.

Therefore this section on "DOM" is divided into two sections:

  1. DOM Level 0. The "DHTML" section covers the W3C DOM HTML, W3C DOM CSS, and browser proprietary DOMs that pertain to the browser, HTML, and CSS.
  2. DOM Level 1+. The "W3C DOM" section covers the W3C DOM Core (and a smattering of browser proprietary DOMs) that pertains to generic XML documents.


GeorgeHernandez.comSome rights reserved