首頁  >  文章  >  php框架  >  yii2高階版如何初始化

yii2高階版如何初始化

王林
王林原創
2020-02-19 16:50:072363瀏覽

yii2高階版如何初始化

初始化yii2環境需要執行腳本:(在yii2的根目錄下方)

./init

(相關教學建議:yii框架

執行過程中的log如下:

[root@nsyong advanced]# ls
backend  common  composer.json  composer.lock  console  environments  frontend  init  init.bat  LICENSE.md  README.md  requirements.php  tests  vendor  yii.bat
[root@nsyong advanced]# ./init
Yii Application Initialization Tool v1.0
 
Which environment do you want the application to be initialized in?
 
  [0] Development
  [1] Production
 
  Your choice [0-1, or "q" to quit] 0
 
  Initialize the application under 'Development' environment? [yes|no] yes
 
  Start initialization ...
 
   generate backend/config/main-local.php
   generate backend/config/params-local.php
   generate backend/web/index.php
   generate backend/web/index-test.php
   generate frontend/config/main-local.php
   generate frontend/config/params-local.php
   generate frontend/web/index.php
   generate frontend/web/index-test.php
   generate console/config/main-local.php
   generate console/config/params-local.php
   generate yii
   generate common/config/main-local.php
   generate common/config/params-local.php
   generate cookie validation key in backend/config/main-local.php
   generate cookie validation key in frontend/config/main-local.php
      chmod 0777 backend/runtime
      chmod 0777 backend/web/assets
      chmod 0777 frontend/runtime
      chmod 0777 frontend/web/assets
      chmod 0755 yii
      chmod 0755 tests/codeception/bin/yii
 
  ... initialization completed.
 
[root@nsyong advanced]# ls
backend  common  composer.json  composer.lock  console  environments  frontend  init  init.bat  LICENSE.md  README.md  requirements.php  tests  vendor  yii  yii.bat

初始化完成後,會出現yii文件,以及其他的一些文件初始化配置,以及修改文件權限等等。

更多程式相關內容,請關注php中文網程式設計入門欄位。

以上是yii2高階版如何初始化的詳細內容。更多資訊請關注PHP中文網其他相關文章!

陳述:
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn