Back to JavaScript Course
JavaScript Course
When a web page is loaded, the browser creates a Document Object Model of the page. It is the tree representation of the HTML document. This DOM tree can be modified with the help of JavaScript.
The Document Object Model (DOM) is a programming interface for HTML and XML documents. It represents the page so that programs can change the document structure, style, and content. The DOM represents the document as nodes and objects. That way, programming languages can connect to the page.
HTML DOM methods are actions you can perform (on HTML elements). HTML DOM properties are values (of HTML elements) that you can set or change.

JavaScript and DOM
- JavaScript can add new HTML elements and attributes.
- JavaScript can change any HTML elements and attributes in the page.
- JavaScript can change all the CSS styles in the page.
- JavaScript can remove existing HTML elements and attributes.
- JavaScript can add and listen to HTML events like onClick, onScroll etc.
Lets see different concepts in DOM
- All About Modifying HTML Elements
- All About Events