by Brian Bondari and Everett Griffiths
At root, this book is an excellent overview of the techniques and issues which will be encountered by any developer — however experienced — when they are authorizing a plug-in using the WordPress plug-in API in WordPress 3. In particular, I appreciated the emphasis on organization and coding best practices. I’ve worked with plenty of plug-ins, and there’s a lot of ugly, unmaintainable code out there. (And I’ve written some of it, too!) The fact that anybody looking to develop a plug-in who uses this book as a major reference will also get a guide to some best practices in writing software is a definite bonus.
The authors are very realistic about the limitations and benefits of the WordPress plug-in system. They observe that WordPress has a great deal of flexibility when it comes to coding style and organization — and the result is that there’s a low resistance to entry. Great for beginners, but it does mean that trusting the code you find is something you shouldn’t do blindly. Clearly the authors want to emphasize that anybody looking to begin developing plug-ins should give some significant thought to the sustainability and quality of their work. Kudos to them!
The book doesn’t cover an enormous number of different API functions, but it does give a good overview of the key hooks that are needed to get started programming for WordPress. Given the scope of what can be done in WordPress, it’s really a better solution to solidly introduce some of the core techniques rather than try and cram a huge number of concepts down the throats of their readers.
I found the systematic approach taken by the book to be extremely effective — I appreciated that the book intentionally had the reader introduce common errors into their plug-ins. Having encountered most of those issues by accident somewhere along the line, it’s tremendously valuable to already have been made aware of some key elements.
I do think that this is a good book, and very worthwhile for the beginning plug-in developer. There are a few additional areas which I would have liked to have seen covered, however.
Although the book is very thorough in addressing programming best practices, it doesn’t address the quality of output code at all. Valid HTML, consistent use of elements, semantics, and accessibility are all issues which deserve a significant mention in the programming of a WordPress extension — however easily the plug-in can be maintained, if it doesn’t produce high-quality output, this can be a major disadvantage for the plug-in. It is very dissatisfying to install a plug-in which does exactly what you need it to, but produces output which can’t easily be styled or doesn’t meet the standards required for your web site.
Nonetheless, there are no other issues which I felt were truly missed — the book is well-written, thorough, and methodical. I can highly recommend it to anybody looking to start authoring WordPress plug-ins.
Note: although this review was not paid, I was provided with a free review copy by Packt publishing in exchange for the review. It was definitely a worthwhile trade!