Composer is a tool that PHP uses to manage dependency (dependency) relationships. You can declare your dependencies on the External tool Library (libraries) in your project, and Composer will help you install these dependent library files.
: http://docs.phpcomposer.com/download/
I use the win7, direct download Composer-setup.exe global installation
1. Create your own project directory?
D:\phppro?
Create the Composer.json file with the following contents:
{
"Require": {
}
}
2. command line into the project directory to execute composer update?, after success will generate the Vender directory, which is some basic files
3. Find the composer package you need, add to the require in the Composer.json file as follows
For example, the package address is: Https://github.com/package/name?
? {
"Require": {
"Package/name": "Dev-master"?
}
}
Execute composer Update command?, after success, Vender will appear under the corresponding package directory package/name/...
? A few learning URL addresses:
Composer Chinese Learning station: http://www.phpcomposer.com/?
Build your own PHP framework with Composer step-by-step
How do I create a composer/packagist package (PHP) of my own?
PHP Composer Package Manager