O'Reilly logo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Working with the DOM

Book Description

The Document Object Model is the tree-like data structure that represents a web browser’s model of a web page. This lesson introduces the DOM, some DOM-specific terminology, and shows you how to use JavaScript to query, manipulate, and create DOM elements.

Why is it important?

Any use of JavaScript to manipulate pages requires understanding the DOM and the techniques available to accomplish common tasks, such as selecting specific elements or modifying the content of elements.

What you’ll learn—and how you can apply it

Learn what the Document Object Model is and how to use JavaScript to select, manipulate, and create DOM elements.

This lesson is for you because…

  • You’re a web designer or new frontend developer who needs to understand how to manipulate web pages dynamically with JavaScript


  • Basic familiarity with HTML and JavaScript

Materials or downloads needed in advance

  • None