There are two YII2 templates available:
- Basic YII2 Application Template – a basic frontend application template.
- Advanced YII2 Application Template – consist of common, frontend, backend and console
Below are the the steps for an easy installation of yii2-advanced template using composer
To install YII2 advanced template using composer in windows through command line the minimum requirement for YII2 is that your Web server supports PHP 5.4.0.
The installation require following steps:
1: If you don’t have composer, download it from https://getcomposer.org/Composer-Setup.exe
2: To check tthe composer is install or not use below command
c:\composer3: Go to your project folder like c:\xampp\htdocs and run composer command to install YII2 advanced template
c:\xampp\htdocs>composer create-project --prefer-dist yiisoft/yii2-app-advanced yourprojectfolder c:\xampp\htdocs>cd yourprojectfolder
During installation this screen will appears
4. After this run php init command to initialize the application. The initialization will generate the entry scripts and config files for your application.
After this running tis command this screen will appears
Then enter 0 to start with development profile
This will create the following directory sctructure
Then finally run your application