The Document Object Model is a standard of the W3C (World Wide Web). It defines the standard for accessing a document. In other words, the Document Object Model provides a platform for programs and scripts to dynamically access and update the structure, style, and content of a document. The Document Object Model is a W3C (World Wide Web) standard. It defines the standard for accessing a document. In other words, the DocumentObject model provides a platform for programs and scripts to dynamically access and update the structure, style, and content of a document.
feature of javaScript
- Javascript can access and change all the tags of the webpage.
- Javascript can access and change all the attributes of the webpage.
- Javascript can remove old html elements such as Tags, Attributes from the webpage.
- New tags and attributes can be added to the webpage by Javascript.
- Javascript can change all the CSS styles of the webpage.
- New events can be created by Javascript.
NOTE:
Document means Webpage.
Object means different elements like tags, attributes etc.
Model means texture or structure.
Example
<!DOCTYPE HTML>
<html>
<head>
<title>About elk</title>
</head>
<body>
The truth about elk.
</body>
</html>
DOM represents HTML as a tree structure of tags