Re: Upload/Copy Problem.
| From: | jeremy brand | Date: | Fri, 18 Aug 2000 20:45:38 +0000 |
| Subject: | Re: Upload/Copy Problem. | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-12534@lists.php.net to get a copy of this message | ||
Most likely it is a permission issue. Your webserver probably runs as
the user 'nobody' (or equivilant).
Make sure that where you are trying to copy the file has correct
permissions to allow 'nobody' to do so.
So, if you are trying to copy() it to //home/httpd/htdocs/foo, then
foo had better look something like this:
shell command> ls -l /home/httpd/htdocs | grep "foo$"
output> drwxrwxr-x 2 nobody nobody 1024 Apr 26 10:00 foo
Notice that 'nobody' owns the 'foo' directory.
Hope this helps,
-jeremy brand
_______________________________________________________________________
GnuPG Fingerprint: 9F5E 95E0 1CC2 E054 84EA 6099 8ACD 9DBA D2C0 5EA9
_ http://www.jeremybrand.com/jeremy/brand/jeremy_brand.html
for more __
On Fri, 18 Aug 2000, James Herrmann wrote:
> Hi,
>
> I'm using a PHP Collaboration application that uploads files to the
> server via a form. I know that the uploads are successful because if I
> do a x = filesize($filename); and print the value of x the byte size
> matches the actual file size exactly.
>
> PHP automatically destroys uploaded files after the receiving script
> finishes executing. This makes it necessary to copy the file elsewhere
> before the original uploaded file is destroyed. But, my system will not
> allow me to copy the file!
>
> I have tried the copy command. I have tried reading the file contents
> and dumping it into a new file with fopen(), fread() and fwrite(). I
> have tried doing a copy via the system level using exec(), system(),
> shell_exec(), and passthru(). All of this to no avail!
>
> One word: help!
> --
> James Herrmann
> WebTeam Programmer/Analyst
> Saint Louis University
> hermannj@slu.edu
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>
>