CakePHP chmod question

孤街浪徒 提交于 2019-12-11 06:18:36

问题


I downloaded CakePHP and put it in my www directory. I enabled mod-rewrite and all that and changed my document root. But I still get permission denied errors in my apache error log because Cake can't require the files from other directories. It's almost as if I need to chmod every single directory to 777 in order to make this work. I know that's not right but can someone tell me if I did not install it correctly or what to CHMOD. Because so far it's literally every folder I'm going through CHMODing right now.


回答1:


Try

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

you can get the webserver user with

ps -aux | grep apache #or whatever your web server is


来源:https://stackoverflow.com/questions/7179537/cakephp-chmod-question

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!