Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
Chapter 3
The Document Object Model
WHAT YOU WILL LEARN IN THIS CHAPTER:
A web page is an HTML document containing markup tags and content. But, as you develop web apps, you’ll find it more helpful to think of the document as a tree-like structure filled with branches, limbs, and leaf nodes. This “document as hierarchy” concept is exactly what is meant when you hear the term Document Object Model (DOM).
In this chapter, I introduce you to the DOM and walk you through the basics you need to access and manipulate the DOM from your application code.