Yii structure doesn't work on mac

When creating a project in applications/xampp/htdocs using the yii framework in the terminal, it shows an error as permission denied . I can create projects in all other folders.

Here is the terminal command I wrote:

 % php yii/framework/yiic.php webapp /Applications/XAMPP/htdocs/pjt_1 

Error shown:

 PHP Error[2]: mkdir(): Permission denied in file /Applications/yii/framework/console/CConsoleCommand.php at line 457 #0 /Applications/yii/framework/console/CConsoleCommand.php(457): mkdir() #1 /Applications/yii/framework/console/CConsoleCommand.php(455): WebAppCommand->ensureDirectory() #2 /Applications/yii/framework/console/CConsoleCommand.php(366): WebAppCommand->ensureDirectory() #3 /Applications/yii/framework/cli/commands/WebAppCommand.php(96): WebAppCommand->copyFiles() #4 /Applications/yii/framework/console/CConsoleCommandRunner.php(68): WebAppCommand->run() #5 /Applications/yii/framework/console/CConsoleApplication.php(92): CConsoleCommandRunner->run() #6 /Applications/yii/framework/base/CApplication.php(162): CConsoleApplication->processRequest() #7 /Applications/yii/framework/yiic.php(34): CConsoleApplication->run() 

What to do to allow access to the xampp folder?

+4
source share
2 answers

Right-click on the pjt_1 folder and select Get Info.

In the pop-up window, select the Sharing and Permissions tab.

If he is no longer talking about this as an experiment, change the privilege next to "all" to "Read and write." Then try creating the Yii application again from the terminal.

+2
source
 sudo yii/framework/yiic webapp pjt_1 
+1
source

All Articles