我下载了 CakePHP 并将其放在我的 www 目录中。我启用了 mod-rewrite 以及所有这些,并更改了我的文档根目录。但我的 apache 错误日志中仍然出现权限被拒绝的错误,因为 Cake 无法需要
来自其他目录的文件。几乎就像我需要将每个目录 chmod 为 777
才能完成这项工作。我知道这是不对的,但是有人可以告诉我我是否没有正确安装它或者 CHMOD 是什么。因为到目前为止,它实际上是我正在执行 CHMOD 的每个文件夹。
最佳答案
尝试
chown -R <webserver_user> <cake_dir> #set the owner of your cake dir recursively to your webserver
chmod -R 755 <cake_dir> #set the permissions recursively
您可以通过以下方式获取网络服务器用户
ps -aux | grep apache #or whatever your web server is
关于php - CakePHP chmod 问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7179537/