Document Object Model – DOM | What is DOM | Learn Data Object Model | DOM Stands for | Object Model Example | Document Object Model Books

Document Object Model - DOM | What is DOM | Learn Data Object Model | DOM Stands for | Object Model Example | Document Object Model Books

Document Object Model – DOM | What is DOM | Learn Data Object Model | DOM Stands for | Object Model Example | Document Object Model Books

The Document Object Model (DOM) is a cross-platform and language-independent application programming interface that treats an HTML, XHTML, or XML document as a tree structure wherein each node is an object representing a part of the document. The objects can be manipulated programmatically and any visible changes occurring, as a result, may then be reflected in the display of the document.



The principal standardization of DOM was handled by the World Wide Web Consortium, which last developed a recommendation in 2004. WHATWG took over the development of the standard, publishing it as a living document. The W3C now publishes stable snapshots of the WHATWG standard.

History of DOM

The history of the Document Object Model is intertwined with the history of the “browser wars” of the late 1990s between Netscape Navigator and Microsoft Internet Explorer, as well as with that of JavaScript and JScript, the first scripting languages to be widely implemented in the layout engines of web browsers.

Applications of DOM

  • Web browsers

    To render a document such as an HTML page, most web browsers use an internal model similar to the DOM. The nodes of every document are organized in a tree structure, called the DOM tree, with the topmost node named as “Document object”. When an HTML page is rendered in browsers, the browser downloads the HTML into local memory and automatically parses it to display the page on a screen.

  • JavaScript

    When a web page is loaded, the browser creates a Document Object Model of the page, which is an object-oriented representation of an HTML document, that acts as an interface between JavaScript and the document itself and allows the creation of dynamic web pages.

Implementations of DOM

Because DOM supports navigation in any direction (e.g., parent and previous sibling) and allows for arbitrary modifications, an implementation must at least buffer the document that has been read so far (or some parsed form of it).

  • Layout engines

    Web browsers rely on layout engines to parse HTML into a DOM. Some layout engines, such as Trident/MSHTML, are associated primarily or exclusively with a particular browser, such as Internet Explorer. Others, including Blink, WebKit, and Gecko, are shared by a number of browsers, such as Google Chrome, Opera, Safari, and Firefox. The different layout engines implement the DOM standards to varying degrees of compliance.

  • Libraries

    DOM implementations:

    • libxml2
    • MSXML
    • Xerces is a collection of DOM implementations written in C++, Java, and Perl
    • XML for <SCRIPT> is a JavaScript-based DOM implementation
    • PHP.Gt DOM is based on libxml2 and brings DOM level 4 compatibility to the PHP programming language



Thanks for reading the post and keep visits for more updates.



About Ashok.cse

Hi, I'm currently studying for the Bachelor of Technology In Computer Science from Rajasthan Technical University. I am the web developer with 3+ years of experience. my range of developer services including creating the design for new apps and web platforms or building UI design for mobile, tablets or desktops. making UX designs wireframes and layouts concepts and redesigns websites are adapting to mobile and responsive design. I have worked with many clients. I am working professionally with WordPress And Adobe tools.

View all posts by Ashok.cse →

Leave a Reply

Your email address will not be published. Required fields are marked *