mtd
09-03-2005, 03:09 AM
Hi. I have a script that uses fopen() to open and make changes to other files on the server. I developed the script, tested it on one server, and it worked great. However, I tried it on another server and I get:
Warning: fopen(/path/to/file.htm): failed to open stream: Permission denied in /path/to/script.php on line 316
(Obviously the paths are changed for simplicity/security)
Is this a problem with my php, or server config? I contacted the host and - after convincing them my code was valid - they told me I had to chmod everything to 666. The thing is, this worked on the first host with no problems at 644. HELP! If this is not a php issue, please point me in the right direction (or you could help anyway, which would be great...)
Thanks
Warning: fopen(/path/to/file.htm): failed to open stream: Permission denied in /path/to/script.php on line 316
(Obviously the paths are changed for simplicity/security)
Is this a problem with my php, or server config? I contacted the host and - after convincing them my code was valid - they told me I had to chmod everything to 666. The thing is, this worked on the first host with no problems at 644. HELP! If this is not a php issue, please point me in the right direction (or you could help anyway, which would be great...)
Thanks