TJR Forum

Home arrow Book reviews arrow Head Rush Ajax review
Head Rush Ajax review PDF Print E-mail
Written by Jem Matzan   
May 30, 2006 at 02:04 PM

Ajax is on everybody's lips these days, and Web programmers are scrambling to put it into action on their sites. For those who have been left behind, a number of books on the subject have been rushed to market over the past couple of months. O'Reilly's Head Rush Ajax is among the most rushed of that batch. It promises to get you up to speed on using Ajax in Web applications, and from a narrow frame of reference it does just that. However, most people looking for an Ajax primer will be sorely disappointed by this book. Don't blame the author, though -- blame the Ajax hype.

Writing analysis

O'Reilly's "Head First" book series is known for its intelligent, informal teaching style. The archetype for the series is Head First Java, and in terms of style and format, Head Rush Ajax follows in its footsteps perfectly. But where Head First Java failed, Head Rush Ajax has failed doubly so -- when you're finished reading it, while you may understand what Ajax is and how it should be used, you are likely to walk away from this book without the ability to code a site using Ajax techniques. And instead of starting at the beginning, showing readers the Ajax basics and how it is implemented in the most elementary of ways and then building on that knowledge with topics of increasing complexity, Head Rush Ajax dives right into a database-driven example that was originally written in PHP. To make matters worse, the example is a total farce -- it's a Web application that you're unlikely to see in the real world. So right off the bat, you're being shown complex Javascript functions that may be too difficult for readers to understand. The author says that the book does not require you to have more than a basic understanding of HTML, CSS, XML, and Javascript, but if you aren't able to write your own Javascript functions and if you have no prior object-oriented programming experience, you'll be left behind in the first chapter.

Head Rush Ajax does not show you different aspects of Ajax in an organized fashion; it is merely a collection of example Web applications that the author shows you how to add Ajax functionality to. A significant portion of the book is dedicated to things peripheral to Ajax, like the document object model and JSON. Really this should not have been made into a "Head First" book at all; it doesn't fit the mold. And perhaps it should have been dedicated more to redesigning bandwidth-intensive Web interfaces than to Ajax specifically.

Putting the book to the test

It's hard to put this book to the test. I have a great deal of Web design experience, and a working knowledge of Java and PHP, and I found Head Rush Ajax to be over my head. I got the impression that it was meant more for people who were already Javascript gurus, despite the author's insistence that you only need to have seen and used Javascript in a Web page before. To most Web designers and developers, a basic familiarity with Javascript means a couple of lines of code -- maybe a single, simple function to control a mouse action or to detect the browser type. And here Head Rush Ajax has you examining object creation, database communication, and multiple functions with complex function calls? If that's the author's idea of basic familiarity, I'd hate to see what he thinks a Javascript expert should be able to do.

The exercises are, as I have pointed out in other "Head First" books, inappropriate for the material. The "Head First" editors need to understand that the only way a book can transform someone into a competent programmer is to make them write code. Not providing example code to stare at and poke around, not offering crossword puzzles of programming terms, not asking to fill in the blanks with the right function -- these are all good ways to get a reader to comprehend a concept, but without any actual coding, you can finish the entire book and dutifully follow all of the examples and still not be able to put this knowledge into practice. A book that deals with a concept like Ajax needs to take a more realistic approach to teaching such a complex subject; that means an introductory primer to object-oriented programming, database interaction, and Javascript. Ajax itself is advanced Javascript and XML, so without more than a "basic understanding" of these technologies, this book is useless.

One positive thing I can say about Head Rush Ajax is that it accurately shows you what Ajax can do, and how it should be used to enhance a user's interaction with Web forms. If you have an existing Web app that you want to see use fewer page reloads, fewer server requests, and less bandwidth, Head Rush Ajax will help you understand how you can do that. However, you can just as easily learn these things from free online tutorials and articles on Ajax -- you don't need a whole book dedicated to the task. If your interest in Ajax significantly deviates from this niche, you'll derive practically no benefit from this book.

Conclusions

As a Web technology, Ajax is nothing new -- it's just a hacky method for combining existing browser-dependent technologies in a way that enhances Web interfaces and reduces bandwidth usage. Because it's only a mishmash of Javascript and XML hacks, its practical uses are few. Perhaps it is due to the narrowness of Ajax that Head Rush Ajax fails so miserably. Other "Head First" books concentrate on broader subjects, like programming languages and design patterns. Overall I consider Head Rush Ajax to be a failure in the "Head First" series, though many people can still derive some benefit from it. My advice is to check out some articles and how-to guides on Ajax before you buy this book, just so you can get an impression of what you're getting into.

Discuss this article or get technical support on our forum.

Title Head Rush Ajax
Publisher O'Reilly
Author Brett McLaughlin
ISBN 0596102259
Pages Paperback, 446 pages
Rating 5 out of 10
Tag line A caffeinated learning guide to the world of dynamic Web pages.
Price (retail) U.S. $25. Buy it from Amazon.com

Copyright 2006 Jem Matzan.

Creative Commons License

This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 2.5 License.

<Previous   Next>

The Jem Report is part of the JEM Electronic Media network of information technology Web sites.
Spammers can email us here