Book review: CMS Design Using PHP and JQuery
Note: This article was originally published at Planet PHP on 24 February 2011.A couple of weeks ago I got a request from Packt Publishing to review the book "CMS Design Using PHP and JQuery". I accepted the offer because we're using more and more JQuery in our applications these days and I thought this book would give me a better insight in how to best use JQuery.
It was nice to see JQuery has a variety of plugins to get things done, most of the plugins discussed in the book were developed by the author himself.
I do like the way Kae Verens (@kae_verens) breaks up a CMS basic functionality and targets it one by one to describe it's functionality and purpose. Without the code samples, this book is a good guide for anyone who wants to build a home-grown CMS.
It's not bad, it's worse!
Since the audience for this book are beginner to intermediate PHP developers, I can only curse at the author to be more responsible. Never use meaningless variables like $a, $b, $c!!!
Filtering and Validation of received data was something I missed in the code.
Another thing, if you use SPL functions like DirectoryIterator to traverse a directory on your filesystem, use the SPL methods that come with it (e.g. $dir-isDot() to verify if it's a "." or "..").
At the end of the book the author says this application only works on a *NIX platform. I think this statement reflects how this application is build: poor design.
After reading this book, I should advice Packt Publishing to put a sticker on it "Warning: explicit content - bad coding practices" as this book is dangerous in the hands of novice PHP developers.
I'm very sorry for the authors and Packt Publishing as the topic of this book is very promising and could be a good read for everyone, but at this point with this type of coding I strongly advice people NOT to buy this book. Maybe a next editiona