Category: PHP

  • Dependency Injection Container – simple implementation

    If you’ve ever used any modern framework you’ve most likely used a Dependency Injection Container, also known as a DI container. Sometimes it can feel like magic, you ask it for a class and it will give said class regardless of how many other classes it depends on. In this article I’ll implement a simple…

  • Singletons and how to use them

    I believe it’s customary for every coding blog to have a rant about singletons, and this one is no different. It is called coderambling after all. I’m not here to tell you how to live your life, if you want to use singletons feel free to do so. But I also believe it’s important to…