Is there a consensus on how plugins should be implemented in a PHP application?
I\'ve looked into the observer pattern which comes close, it\'s really just a notificati
I think an Events Dispatcher is a nice and clean way to implement plugins, or any extension for that matter. An Events Dispatcher is an implementation of the Observer pattern, and is being used in symfony, Symfony2 and Zend Framework 2 (beta).
Looking through any of that source on github will make for some interesting reading. Though, an interesting bit of information can be found here:
http://components.symfony-project.org/event-dispatcher/trunk/book/02-Recipes
I wrote an Events and Hooks class a few years back for a project, I'll post that here if I can find it.