Function.Copy error question
martinmike2 - August 22, 2008 - 13:54
Hello,
I am trying to parse several text files to create a "super array" for a blobk module I am creating. My directory has been chmod'd to 777 and i am still getting:
warning: copy(VatsimPHPversions.txt) [function.copy]: failed to open stream: Permission denied in /home/zhuartcc/public_html/newsite/includes/common.inc(1537) : eval()'d code on line 11.
now, my public_html directory is not 777, it is 750. So the Owner group is the only one with write permissions. Does the module not belong to the owner group? I have serious misgivings about chmoding the over-riding directory and makeing it more vulnerable.
Any help with this would be greatly appreciated.

It's all about permissions
Here's what you need to do to fix your problem:
1- Find out what user apache (or whatever webserver you're using) is running as
2- Find out what group(s) the user from #1 belongs to
3- Make sure the source directory -- public_html -- is readable by that group (750 is fine)
4- Make sure the destination directory is writable by that group
Other things can make this error occur -- SELinux, GRSecurity, POSIX ACLs and such, but I doubt that's the case here.