Five common PHP design patterns

Over at IBM Developer Works there's an interesting article on PHP patterns. If you've never come across patterns before it's a good introduction. Just remember that these methods of solving software problems are most useful when you've got lots of code. Using the MVC pattern to print "Hello World!" is probably a little overkill!

For the curious, the patterns covered are: factory, singleton, observer, chain-of-command and strategy.

Elsewhere on you can find a collection of design patterns. Vlado updated his collection recently and there's now 20 techniques or patterns. He openly admits that, 'not all can be considered "officially" design patterns, but to be honest I don't really care.' (via)

Author: Donncha

Donncha Ó Caoimh is a software developer at Automattic and WordPress plugin developer. He posts photos at In Photos and can also be found on Google+ and Twitter.

Leave a Reply