This tutorial is a work in progress created at 2015.02.11 and updated at 2015.02.17. It’s tested with CodeIgniter 3.

Well… It’s that time when we should stop repeating ourselves. The DRY philosophy tells us that maybe we should use our time doing things faster than repeating the same steps for basic CRUD in our models. I’ve talked about the MY_Model subject in the past, but we can improve a lot on that.

A few years ago, Jamie Rumbelow wrote a great book named CodeIgniter Handbook in three volumes, in which he manages to bring Ruby philosophy in the world of CodeIgniter. In the book he talks about Convention over Configuration, trying to apply design principles like Don’t Repeat Yourself (DRY) and RESTful style to CodeIgniter. Continue reading →