See disk on module
odel) A programming interface (API) from the W3C that lets applications and scripts access the content of HTML, XML and XHTML files in a hierarchical tree structure. The DOM was introduced in 1998.
A Web Page Looks Like a Tree
The DOM implementation lays out the tags in the Web page as a hierarchical tree. In 2000, Level 2 (DOM2) gave the programmer a standard way to handle events associated with elements such as mouse down, mouse click and mouse over. Events may be preprocessed at any tag location from the top of the tree to the target tag at the bottom ("capture" phase) and then back up ("bubbling" phase). These phases were implemented to be backward compatible with earlier Netscape and IE browsers.
XML Data Looks Like a Database
The DOM converts XML documents into a hierarchical node tree in memory that looks like a database record. The node tree allows updating in a similar manner to database updating, making data exchange between XML documents and databases more straightforward. Without DOM turning the document into an object model and handling the updating, the text and tags in an XML document would have to be scanned sequentially and rearranged by the program. See DOM implementation
, DOM application
and object model
Nodes in an XML Record
DOM converts (parses) an XML document into a hierarchical node tree. Writing an XML update program is then similar to writing a database update program, using the same kinds of functions available in a database management system (DBMS).