I recently used a trial subscription to Packt Publishing and decided to try a number of their books, one of which was Yii2 By Example by Fabrizio Calderelli.

The general concept of this book is excellent. Fabrizio takes you from basic introduction (installing composer, starting new basic and advanced projects, installing widgets, …) and slowly builds upon each concept chapter to chapter while building a hotel style room reservation system. You can tell the author clearly knows the subject very well.
Sadly, however, where the book falls apart, especially for any novice developer just trying to get their feet wet with Yii2, is the fact that there are a slew of
- Mistakes and omissions
- PHP syntax errors
- Missing ; at the end of PHP commands
- Extra parenthesis
- Yii coding errors
- Missing use statements in Yii code
- Missing Namespace statements
- Incorrect variable names so that they don’t get properly passed between the controller, model and views
- …
- SQL syntax errors
- Extra commas
- Missing clause (without which the commands won’t execute)
- …
- Images not reflecting what is written in the text
- Etc.
throughout the book making actually completing the course material impossible.
There are sections where you are told to use a view, but it was never created! Then in the next section they state “This is how the file … changes” and then you can sometimes backward engineer the file and finish the previous section. Although I have managed to get around most problems to complete the book, sometimes spending hours to figure out that the author forgot to include a use statement, etc… I still have not managed to complete chapter 6. Lucky for me, chapter 7 did not continue what was being done in Chapter 6, otherwise that would have been the end of the book for me.
What amazes me, and shows the lack of quality checking by PACKT and the author, is the simple fact that copying the code into a PHP editor instantaneously flags many syntax errors. So, many of the issues would have easily been spotted just with a simple copy/paste.
All of the above clearly demonstrates that PACKT and the author never truly followed through the book’s content from start to finish themselves to ensure that it was bug free.
I do like the book on it’s whole, but because of the quantity of errors and the target audience, I can’t rate the book any higher than a 4 out of 10! Had PACKT, or the author, actually done a minimal amount of Quality Assurance this book would be worthy of 9 or 10 without hesitation!!!