Results 1 to 4 of 4
Alright, in a user's public_html I try to run a script that simply copies an image file from one directory in public_html to another, but I get a "Permission Denied" ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 06-24-2003 #1Just Joined!
- Join Date
- May 2003
- Posts
- 24
Using user public_html thing
Alright, in a user's public_html I try to run a script that simply copies an image file from one directory in public_html to another, but I get a "Permission Denied" when I try to do that...
I have no idea why. Here is the error.
Warning: copy(t_2.jpg) [function.copy]: failed to create stream: Permission denied in /home/carshow/webspace/copy.php on line 3
- 06-24-2003 #2Linux Engineer
- Join Date
- Apr 2003
- Location
- Sweden
- Posts
- 796
Verify that you have permissions on the file on the filesystem and to the directorys you want to copy the file to, if not change the permissions with the cmod-command.
RegardsRegards
Andutt
- 06-24-2003 #3Linux Guru
- Join Date
- Oct 2001
- Location
- Täby, Sweden
- Posts
- 7,578
The scripts run as the "apache" user, so the target directory needs to have write access for the apache user.
If this is a CGI program, you can configure Apache's suEXEC mechanism to make them run as the owning user.
- 06-24-2003 #4Just Joined!
- Join Date
- May 2003
- Posts
- 24
Thanks. I changed the permissions and I'm all set now.
Now I'm out to get imagemagick to work on my site


Reply With Quote
