Review of Head Rush AJAX

Head Rush AJAX

I recently finished reading Head Rush AJAX and would like to share my comments on the book.

This book is written by Head First Labs and is the first of the series I have read. I picked it up because of a recommendation from a friend. I remember looking with disdain at the books in the series when I had seen them on the shelf. I remember thinking, “They look so elementary, we don’t need another ‘For Dummies’ series”. I, like most computer people, have picked up and read a “For Dummies” book, but after you get through your second, they really loose their allure. My first three technology books were from that series, and I have never committed to reading another one.

When it comes to Head First AJAX the phrase “Never Judge a book by its Cover” has never been more true. If you look at the cover and see the guy doing an one handed handstand you might not want to take the book seriously, but this is a serious book with a serious introduction to a very new and very powerful technology.

About the Reader

It is important to understand the perspective of this review. When I picked up this book I head been reading the Javascript: The Definitive Guide. This is the canonical book on Javascript, and while it is very informative it is not a very practical straight read. I wanted to give up after about 100 pages, this book offered a quick alternative so I picked it up.

I’m a strong HTML and CSS programmer, I have worked with various web technologies like Rails and PHP. I wouldn’t qualify myself as an expert, but I’m no stranger to web programming. However, up until recently, I have had one GAPING flaw in my resume when it comes to web work, I have had little to no knowledge of javascript. I used a snippet of javascript back on a website I had written many years ago that responded to an onHover event to replace an image, but that was the extent of my real JavaScript experience. Realizing this hole and having some time on my hands I set about fixing it.

Book Content

This book covers the following topics:

  • Intro to JavaScript
  • Discussion of why there is a need for AJAX
  • Basic PHP on the web server side
  • Introduction to Web Security (defending against SQL injection)
  • The Document Object Model (DOM)
  • Introduction to JSON

Each of the topics in the list above is described using both pictures and instructions. There are several cornerstones to the Head First approach, but two of these really stuck with me. Firstly, everything that is important is repeated. Secondly, information is presented in both a textual and graphical format. Text is placed next to pictures to get your mind to remember it. This is EXACTLY how I learn, so this book worked great for me.

Criticisms

I really liked the book, but there are a few areas where I felt like the speed of the book was too fast and some areas where I felt they could have used improvement. The last chapter is when they first introduce JSON. The introduction is a bit rushed, and they use the blanket “eval()” statement in javascript to execute the JSON code. Being a traditional programmer, I’m always apprehensive of using an eval function, especially in the case where are receiving the code to eval from a response object. There is no talk about the security risks of using this function until the Appendix.

My second issue is the discussion of frameworks doesn’t occur until the Appendix. While understanding the fundamentals of AJAX is very important, in practice frameworks are more practical then rewriting code that already exists out there. There is a discussion of frameworks and how to use them, but that isn’t until Appendix I.

In short, Appendix I is not an optional read. The contents of this Appendix I feel are completely necessary in order to actually start using AJAX, and the fact that it is listed as an Appendix is misleading.

Conclusion

I would strongly recommend this book to someone in my position. It gave a great introduction to AJAX for someone already familiar with web programming. I could see how users without any experience in web programming might get lost by this book, but it was PERFECT for me. I have since purchased my second book from Head First Labs, and will hopefully write a review of that title shortly.

One thought on “Review of Head Rush AJAX

  1. Gald you enjoyed the head first format. I’ve found the diagrams and notebook-style scribbles to be really helpful and familiar. It is a shame about the cover, they’re a little off-putting when you consider yourself an experienced developer. That said, once you get over the potential embarrassment of not having an industry-accepted-black-and-white-animal animal on the cover of your tech book you can really learn a lot more effectively with these.

    Your note of using a raw eval() for JSON is usually addressed with using a JSON parser as noted in http://www.json.org/js.html

    However, most everybody I know is using eval() straight-up so, for better or worse, the example they use is in keeping with what developers will likely see in the real world.

Leave a Reply

Your email address will not be published.