I've been told I need to set some file permissions for my php scripts. how do I do this so I can set a file to something other than 006 permission? (right now, only 006 works).
The main question is, how do I make a group?
|
I've been told I need to set some file permissions for my php scripts. how do I do this so I can set a file to something other than 006 permission? (right now, only 006 works). The main question is, how do I make a group? | ||||
|
feedback
|
006 it will be useless ... since the user and the group can't read the file but allows everybody to read and write - perhaps is the other way around 600
| |||||
feedback
|
PHP executed from your web server should be executed as your web server user, and PHP executed from your logged-in user should be executed as that user. As such, as long as your logged in user of 'david' is part of the 'dev' group (as 'apache' should be too) and all files are owned by apache:dev, you should be good to go. | |||
|
feedback
|
ls -al filename- the third and fourth column should show you the user and group. Also, I really doubt 006 is the only permission set that works. It means that everyone can read and write to the file except for the user and group. Typically, the webserver shouldn't be able to write. – James Lawrie Jan 20 '11 at 23:28