kb:document_object_model

Differences

This shows you the differences between two versions of the page.


Previous revision
kb:document_object_model [2023/03/25 20:05] (current) Henrik Yllemo
Line 1: Line 1:
 +====== Document Object Model (DOM) ======
 +
 +Document Object Model (DOM) is a cross-platform and language-independent interface that treats an XML or HTML document as a tree structure wherein each node is an object representing a part of the document. 
 +
 +<callout type='primary' title='What is Document Object Model?' icon='fa fa-question-circle'>
 +The Document Object Model (DOM) is a programming interface for HTML and XML documents. It represents the document as a tree-like structure of objects that can be manipulated with JavaScript or other programming languages.
 +\\
 +\\
 +
 +The DOM provides a way to access and manipulate the content and structure of an HTML or XML document. It allows developers to dynamically change the content, structure, and style of a document in response to user events or other changes.
 +The DOM tree is hierarchical, with each element represented as a node in the tree. The top-level node of the tree is the Document node, which represents the entire HTML or XML document. Below the Document node are the Element nodes, which represent the HTML or XML elements, such as p>, div>, or table>. The Element nodes can have child nodes, such as other elements, text nodes, or attributes.
 +\\
 +\\
 +By manipulating the DOM tree, developers can create dynamic web pages, perform client-side validation, and enhance user interactions. For example, JavaScript can be used to add, remove, or modify elements and attributes of the DOM, respond to user input, and dynamically update the content of the web page.
 +
 +</callout>
 +
 +
 +
 +{{wp>Document Object Model}}
 +<callout type="primary" title="Related:">
 +  * [[taxonomy:taxonomy_of_dom|Taxonomy of Document Object Model]]
 +</callout>
 +
 +<callout title="External links:">
 +  * https://developer.mozilla.org/en-US/docs/Web/API/Document_Object_Model
 +</callout> 
 +
 +
 +{{tag>kb  architecture programming       }}