更新时间:2022-05-09 03:35:41
在 Windows 上,您只需转到框架文件夹并键入:
On windows you just go to your framework folder and type:
yiic webapp pathToYourNewProject
yiic 将默认为 yiic.bat,因此您无需指定任何 php.exe(我并不是说它不会那样工作).新项目的路径可以是相对的也可以是绝对的,以下是一些示例:
yiic will default to yiic.bat so you don't need to specify any php.exe (I'm not saying that it wouldn't work like that). and path to your new project can be relative or absolute, here are some examples:
-- C:
|
-- sandbox/
|
--yii/
| |
| --framework/
| |
| --yiic.bat (for Window)
| --yiic.php (for Linux)
--newWebApp/
要在 Windows 上创建,我使用:
To create on Windows i use:
cd c:sandboxyiiframework
yiic webapp ../../newWebApp
type yes when prompted and you're done
或
cd c:sandboxyiiframework
yiic webapp c:sandbox
ewWebApp
type yes when prompted and you're done
在 Linux 上创建:
To create on Linux:
cd /media/sf_sandbox/yii/framework/
./yiic webapp ../../newWebApp