Chapter 38. Handling file uploads

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am using the code at the top of this chapter to upload a file and move
to a given destination directory. I get the following error messages and
my file is not to be found. The only thing I am changing is where I want
the file to be stored.
 
Thanks.
 
Warning:  move_uploaded_file(/images/tim.jpg): failed to open stream: No
such file or directory in
/usr/hsphere/local/home/ice-admi/iceagents.com/CxDatabase/fileuploadh.ph
p on line 20



Warning:  move_uploaded_file(): Unable to move '/var/tmp/phpcrIqVo' to
'/images/tim.jpg' in
/usr/hsphere/local/home/ice-admi/iceagents.com/CxDatabase/fileuploadh.ph
p on line 20


Possible file upload attack!
Here is some more debugging info:Array
(
    [userfile] => Array
        (
            [name] => tim.jpg
            [type] => image/pjpeg
            [tmp_name] => /var/tmp/phpcrIqVo
            [error] => 0
            [size] => 17024
        )

)


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux