The example in this article describes how to install the Yii framework using Composer. Share it with everyone for your reference, as follows:
It is now popular to use Composer to install PHP frameworks. Composer is a tool used by PHP to manage dependencies. Frameworks or services such as Yii, Laravel, Qiniu, etc. all use Composer as the preferred tool for installation.
The following is an example of downloading and installing the Yii framework to learn how to use Composer to install the PHP framework:
First go to Composer to download and install this tool.
Install Yii via Composer
This is the preferred method to install Yii2.0. If you don't have Composer installed yet, you can follow the instructions here to install it.
After installing Composer, run the following command to install the Composer Asset plug-in:
Copy the code The code is as follows:
php composer.phar global require "fxp/composer-asset-plugin:1.0.0"
Install the basic application template, run the following command:
Copy the code The code is as follows:
php composer.phar create-project yiisoft/yii2-app-basic basic 2.0.4
Copy the code The code is as follows:
php composer.phar create-project yiisoft/yii2-app-advanced advanced 2.0.4
Reprinted from: Xiaotan Blog http://www.tantengvip.com/2015/05/composer-php/
Readers who are interested in more Yii-related content can check out this site’s special topic: "Getting Started with Yii Framework and Common Techniques" Summary", "Summary of PHP Excellent Development Framework", "Basic Tutorial for Getting Started with Smarty Templates", "Summary of PHP Date and Time Usage", "Introduction Tutorial on PHP Object-Oriented Programming", "Summary of PHP String Usage", " php+mysql database operation introductory tutorial" and "php common database operation skills summary"
I hope this article will be helpful to everyone's PHP program design based on the Yii framework.
The above introduces the method of using Composer to install the Yii framework, including the relevant aspects. I hope it will be helpful to friends who are interested in PHP tutorials.