Murach's JavaScript and DOM Scripting
Advanced DOM manipulation

Many JavaScript applications need to manipulate the DOM tree. That's why this chapter shows you how to detect when the DOM is ready, how to search the DOM, and how to modify it.

Chapter 15 Advanced DOM manipulation
How to detect when the DOM is ready 524
A problem with the load event 524
The code that illustrates this problem 526
How to use a ready method to detect when the DOM is ready 528
The JavaScript library that contains the ready method 530
How to search the DOM 534
How to use a walk method to walk the DOM tree 534
How to use a getElementsByClassname method to search the DOM 538
A JavaScript library for walking and searching the DOM 540
How to modify the DOM 542
How to create new DOM nodes 542
How to add and remove DOM nodes 544
How to use a document fragment 546
The Headlines application 548
The user interface 548
The XHTML file 548
The headlines_library.js file 550
The headlines.js file 552




Murach's JavaScript and DOM Scripting

Learn more about this book

View the table of contents


More about the eBook



Our 100% Guarantee

First, try our books for 90 days. Then, if you aren't completely convinced that our books are the best ones you've ever used, you can return them for a prompt refund...no questions asked.