The Document Object Model (DOM)

One of the reasons you want to learn about JavaScript is that it works so well with the structure used to create HTML documents. Every webpage can be broken down into a mathematical tree structure called the Document Object Model (DOM). Each HTML tag is a node in the tree and these nodes have all types of different attributes, such as text, background color, width, etc.

With JavaScript it is easy to write code that basically says "I want to grab that part of the webpage and change it." In this lecture I review the DOM and talk about how it is related to JavaScript. There is no code associated with this lecture, but if you check under the resources I do include a link to site where you can find specifics on the DOM.