I can't get the fileupload to work and I have no further idea.
my form looks like the standard example:
<form enctype="multipart/form-data" action="upload2_2.php3" method=POST>
<input type="hidden" name="MAX_FILE_SIZE" value="1000000">
<input name="userfile" type="file">
<input type="submit" value=" Send File ">
and in upload2_2 the variable $userfile has the value /temp/phpxxxxxxx.
the upload2_2.php3 site looks like this:
so far seems everything o.k. But I get the following Error:
Warning: SAFE MODE Restriction in effect. The script whose uid is 501 is not
allowed to access /tmp/php00508baa owned by uid 0 in
/usr/local/httpd/htdocs/bisoag/album/upload2_2.php3 on line 8
How can I solve this ? Im running apache on linux (SuSE 6.1) and the /temp
directory has 777 rights.
please help :-(
August 29th, 1999, 02:14 AM
I had some crappy problem like that too.
Make sure the the ownerships on the tmp directory is the same as that run by the web server.
If that does not work, edit your php.ini file and select your own tmp directory!
August 29th, 1999, 04:56 PM
I had problems, mine were down to disk quota for the user 'web'.
Why is your setup running SAFE MODE though, I think that may be the problem as I think I read somewhere there are limitations when in this mode.
September 12th, 1999, 01:57 PM
You can easily switch out of safe mode by editing your php.ini. Also, I doubt it makes any difference, but I use the line:
exec("cp $userfile /home/$usr/public_html/$userfile_name");
to save the file.