Best CakePHP Books To Learn & Master The Framework

Resources Web Development This post may contain affiliate links (read more)

The huge variety of PHP frameworks can be intimidating. I recently covered the best books for Laravel and in this post I’d like to share my favorite books for learning the CakePHP framework.

This is a fairly older framework currently in it’s v3.x stage. It runs on PHP 5.5 and includes support for PHP7. Cake is keeping up with the times and it’s a framework that you may want to pick up for your own PHP projects.

CakePHP Application Development

cakephp app development

Working in an MVC environment can be tricky, especially if you’ve only used generic PHP. The biggest value of CakePHP Application Development is how it teaches you to code PHP with MVC in mind.

This book is fairly old dating back to 2008. However it’s surprisingly resilient even in the current CakePHP environment. The team does have a Cake v3 guide but it’s exceptionally detailed and can be off-putting to newcomers.

I think CakePHP Application Development does a great job explaining the basics of MVC and the structure of a Cake app in an approachable way. Each code snippet is explained in great detail so you learn how the codes actually work.

If you’re brand new to CakePHP then this book would be a fantastic starter’s guide. You will need some knowledge of PHP, but you certainly don’t need to be an expert to move into CakePHP development.

 

Beginning CakePHP: From Novice to Professional

beginning cakephp

As I mentioned earlier I would highly recommend this book as the #1 best intro guide to CakePHP. The format is easy to follow and the author David Golding really knows his stuff.

Beginning CakePHP: From Novice to Professional teaches you individual lessons for CakePHP functionality that eventually lead to a working blog platform. You’ll learn all the fundamentals of Cake development and you’ll have no trouble following along as a complete beginner.

The author has a way with explaining concepts by breaking down source code into bite-size chunks. Early chapters talk about basic MVC stuff while the later chapters get into custom routes, plugins, and database management.

It’s important to note that despite the book’s title it will not make you a professional. But you can start as a complete novice and walk away with a sturdy understanding of CakePHP in practice.

 

Learn CakePHP: With Unit Testing

learn cakephp unit testing

Learn CakePHP: With Unit Testing is a brand new title and it’s one of the newest books you’ll find on the subject of Cake development. It’s also a more advanced book covering unit testing in only 114 pages.

You’ll learn a specific way of developing on Cake with test-driven development(or TDD). With this approach you learn to write code properly the first time, organize your code much better, and you’ll carry over this technique into other areas of web development.

MVC knowledge is crucial to follow this book. You’ll learn model tests and controller tests with specific instructions for working in a CakePHP environment.

Beginners should not pick up this book until they’ve built a couple CakePHP apps from scratch. Once you know enough to move through the process then you’ll want to optimize and make it better. This book will do just that by helping you grasp the most important concepts of CakePHP development.

 

Practical CakePHP Projects

practical cakephp projects

Getting your hands dirty in project work can only lead to a better understanding of PHP development. This is why Practical CakePHP Projects offers so much to the young CakePHP dev who wants to apply the framework to real ideas.

You should already have a good understanding of PHP and at least some basic knowledge of CakePHP. This book isn’t intended for complete beginners but it can be picked up by fairly inexperienced CakePHP devs who are eager to learn.

All coding practices in this book are on point. The code is DRY and should compile well even with Cake v3.

However the examples are somewhat sparse and you move through them quickly. A sample blog and eCommerce shop are two finer points in the book. Yet you don’t really dig too deep because the content is intended for beginner-to-intermediate developers.

Overall it’s a nice book if you want to start with real projects. But I still think Beginning CakePHP would be a better choice for a beginner.

 

CakePHP 2 Application Cookbook

cakephp2 app cookbook

I simply cannot recommend this book enough if you’re into CakePHP. It is not for beginners but it can be used as a reference guide by anyone currently working on a CakePHP project.

The CakePHP 2 Application Cookbook shares over 60 unique recipes for CakePHP development including URL routing, user authentication, and even advanced unit testing in PHP.

Every great framework should have its own cookbook as a reference guide and study aide. The contents in this book are simply fantastic because you really learn the right way to solve common problems on the backbone of CakePHP.

It’s about 350 pages long and does cover basic fundamentals before diving into the complex topics like APIs and Cake shells.

Complete novices should not start with this book. It’s quite detailed and may scare you away from Cake altogether. But once you get past the basics and need some more advanced concepts I would highly recommend a copy of this CakePHP 2 Cookbook. All the recipes still work with Cake 3 and it’s generally flawless cover to cover.

 

Building PHP Applications with Symfony, CakePHP, and Zend

symfony cakephp zend book

This isn’t strictly a Cake book, instead choosing to focus on three of the big PHP frameworks. Building PHP Applications with Symfony, CakePHP, and Zend Framework is your guide to learning the foundations of three primary PHP frameworks and learning the pros & cons of each.

If you’re a PHP developer unsure of where to begin this book might actually set you on the right track. It was released in early 2011 before Laravel was even on the market, but by today’s standards I’d like to think Laravel would also be included.

Still the material in this book covers Cake and Zend brilliantly. I haven’t used Symfony so I can’t say how great the material is. But I did get pretty curious reading through the book so I may have to scoop up some Symfony books and dig in!

You can use this book as an aide to help you understand the benefits of each framework. Some projects may work better on Zend, or you might not even want to learn Zend if it doesn’t suit your style of development.

This book will not teach you CakePHP from scratch. But it will compare how Cake stacks up against other popular PHP frameworks which will give you a more well-rounded understanding of CakePHP and frameworks in general.


I’m always surprised how few CakePHP books are on the market. It may not be the most popular PHP framework but it’s definitely a reliable choice that still powers many legacy apps.

If you’re looking for a free intro guide you could check out the Cake documentation and maybe some free tutorials online. But if these aren’t enough I would definitely recommend grabbing a copy of Beginning CakePHP: From Novice to Professional to get you started.

And if you’re moving forward with CakePHP looking for a quality reference guide then the CakePHP 2 Application Cookbook should fit perfectly as a desk reference.

Tags: