On the SitePoint PHP blog Troels Knak-Nielsen has posted about a new tool he's whipped up to handle dependency injections - Bucket.
I got fed up with the lack of a decent DI-container for PHP, so today I created Bucket. To be clear, what I think is wrong with the currently available containers (at least that I’m aware of) is that they either are unstable, abandoned, require a lot of up-front configuration in external XML-files, or are tightly integrated into some full-stack framework. I had my hopes up for Phemto for a while, but it seems that progress has stalled.
He includes a few bits of examples code in the post showing how to use type hinting, the factory method, callbacks and its support for child scopes. If you'd like to check it out for yourself, you can clone it from github.