mnapoli / php-di-zf1
Integrates PHP-DI to Zend Framework 1
Installs: 7 336
Dependents: 0
Suggesters: 0
Security: 0
Stars: 26
Watchers: 7
Forks: 7
Open Issues: 1
Requires
- php-di/php-di: ~5.0 || ~6.0 || ~7.0
Requires (Dev)
- phpunit/phpunit: ^3.7
Suggests
- zendframework/zendframework1: The complete Zend Framework 1
- zf1/zend-controller: The Zend Controller package only
README
This library provides integration for PHP-DI with Zend Framework 1. PHP-DI is a Dependency Injection Container for PHP.
This project also contains the Zend Framework quickstart configured with PHP-DI.
If you are looking for Zend Framework 2 integration, head over here.
Documentation
The full documentation is available on PHP-DI's website.
Zend Framework quickstart
The quickstart is in the quickstart/
folder. You can look at it to see how PHP-DI can be integrated to a ZF1 application.
To run the quickstart, get composer and install the dependencies:
$ curl -s http://getcomposer.org/installer | php
$ php composer.phar install
Please be aware that the quickstart uses annotations. Since PHP-DI 5 annotations are disabled by default, please follow the installation instructions to enable them.
Note: I tried not to diverge too much from the official quickstart. So the code may look messy, but that's how the ZF quickstart is ;)