DOM Scripting: Web Design with JavaScript and the Document Object Model
Jeremy Keith, Jeffrey SambellsBooks.org participates in affiliate programs including Bookshop.org and the Amazon Services LLC Associates Program. We may earn a commission from qualifying purchases made through links on this page, at no additional cost to you.
Overview
With this second edition of the popular DOM Scripting: Web Design with JavaScript and the Document Object Model comes a modern revision to update best practices and guidelines. It includes full coverage of HTML5 in a new, dedicated chapter, and details on JavaScript libraries and how they can help your scripting.
The book provides everything you'll need to start using JavaScript and the Document Object Model to enhance your web pages with client-side dynamic effects and user-controlled animation. It shows how JavaScript, HTML5, and Cascading Style Sheets (CSS) work together to create usable, standards-compliant web designs. We'll also cover cross-browser compatibility with DOM scripts and how to make sure they degrade gracefully when JavaScript isn't available.
DOM Scripting: Web Design with JavaScript and the Document Object Model focuses on JavaScript for adding dynamic effects and manipulating page structure on the fly using the Document Object Model. You'll start with a crash course in JavaScript and the DOM, then move on to several real-world examples that you'll build from scratch, including dynamic image galleries and dynamic menus. You'll also learn how to manipulate web page styles using the CSS DOM, and create markup on the fly.
If you want to create websites that are beautiful, dynamic, accessible, and standards-compliant, this is the book for you!
What youβll learn
- Apply dynamic behavior to your pages without inserting JavaScript in your markup
- Write scripts that degrade gracefully when JavaScript isnβt available
- Use web standards to ensure cross-browser compatibility
- Harness the power of the DOM to create user-controlled animation
- Also includes an introduction to Ajax
This book is for web developers wanting to expand their knowledge of the DOM to add interactivity and functionality to their web pages.
Table of Contents
- A Brief History of JavaScript
- JavaScript Syntax
- The Document Object Model
- A JavaScript Image Gallery
- Best Practices
- The Image Gallery Revisited
- Creating Markup on the Fly
- Enhancing Content
- CSS-DOM
- An Animated Slideshow
- HTML5
- Putting It All Together
- DOM Scripting Libraries
Synopsis
We know from the success of titles such as Web Standards Solutions, Cascading Style Sheets: Separating Content from Presentation, and the Web Designer's Reference that web designers are increasingly concerned with making sites that don't just look pretty, but are also built using current best practices.
There are three main technologies married together to create usable, standards-compliant web designs: XHTML for data structure, Cascading Style Sheets for styling your data, and JavaScript for adding dynamic effects and manipulating structure on the fly using the Document Object Model.
This book is about the latter of the three. DOM Scripting: Web Design with JavaScript and the Document Object Model gives you everything you need to start using JavaScript and the Document Object Model to enhance your web pages with client-side dynamic effects. Jeremy starts off by giving you a basic crash course in JavaScript and the DOM, then move on to provide you with several real world examples built up from scratch including dynamic image galleries and dynamic menus, and show you how to manipulate web page style using the CSS DOM, and create markup on the fly.