October 2013
Intermediate to advanced
1044 pages
24h 36m
English
CHAPTER 7
![]()
Manipulating the DOM
In the previous chapter, I showed you how to select elements. One of the most powerful things you can do with the selection is to change the structure of the HTML document itself, known as manipulating the DOM. In this chapter, I’ll show you the different ways in which you can alter the structure, including inserting elements as children, parents, or siblings of other elements. I’ll also show you how to create new elements, how to move elements from one part of the document to another, and how to remove elements entirely. Table 7-1 provides the summary for this chapter.
Table 7-1. Chapter Summary
| Problem | Solution ... |
|---|