mercuryfenix Posted August 1, 2007 Share Posted August 1, 2007 I've been playing around with the chmod() but I am going in circles. My last post got bumped down too far and nobody is responding. I am getting the following error with this code: Warning: fopen(rss.xml) [function.fopen]: failed to open stream: Permission denied in /rss/update_rss.php on line 31 Warning: fwrite(): supplied argument is not a valid stream resource in /rss/update_rss.php on line 32 Warning: fclose(): supplied argument is not a valid stream resource in /rss/update_rss.php on line 33 $path="rss.xml"; $file_name=fopen($path,"w"); fwrite($file_name,$body); fclose($file_name); ?> Link to comment https://forums.phpfreaks.com/topic/62936-need-help-with-fopen-and-fwritepleeeease/ Share on other sites More sharing options...
hitman6003 Posted August 2, 2007 Share Posted August 2, 2007 Check the permissions on your file...make sure that the user that runs the web server (IUSR_servername, I think, on windows, whatever the SA set it to on *nix), has write permission to that file. Link to comment https://forums.phpfreaks.com/topic/62936-need-help-with-fopen-and-fwritepleeeease/#findComment-313486 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.