CHAPTER 29
image
Dynamic Objects
Powerful as CSS is, it isn’t really a language, as shown by the recipes in this book having to repeat large chunks of code where only a minor change is required between each, such as a color or width. A language, on the other hand, is very good at repeating things based on only a few lines of code. And that’s where JavaScript fits in, because with it you can bring the dynamic interaction of a web page up an order of magnitude.
What’s more, many of the classes in this chapter allow you to enter values as parameters to create exactly the result you want, including moving objects about in the browser, loading images in ...

Get Web Developer's Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.