Drag the edges to resize the window.

In Projects, you can keep track of your progress as you go throught the tasks. Check each item as you complete it!

Code Editor
Web Browser
JavaScript and the DOM

Document Object Model

The Document Object Model, commonly referred to as the DOM', is the term for elements in an HTML file. Elements are any HTML code denoted by HTML tags, like <div>, <a>, or <p>. Let's use JavaScript to interact with the DOM.

We can select an HTML element with JavaScript by selecting its class attribute, like this:

var header = document.getElementsByClassName('example-class-name');

This would find an element like this in the HTML:

<div class='example-class-name'> ... </div>
Report a Bug
If you see a bug or any other issue with this page, please report it here.