Unable to upload a file, $_FILES array is empty

124 views
Skip to first unread message

Mr Alexander

unread,
May 16, 2013, 8:44:14 PM5/16/13
to jquery-f...@googlegroups.com
Hello,

When i try to upload a file I get an error message and when I try to log the errors I am noticing that I am given the following array for $_FILES:

Why is this the case? Why are files not uploaded? I wish there would be a better way to read the errors.

Array
(
    [name] => Array
        (
            [0] => IMG_2443.JPG
        )

    [type] => Array
        (
            [0] => 
        )

    [tmp_name] => Array
        (
            [0] => 
        )

    [error] => Array
        (
            [0] => 1
        )

    [size] => Array
        (
            [0] => 0
        )

)

Thank you for your support

Mr-Alexander

Arjhun Srinivas

unread,
May 17, 2013, 1:34:34 AM5/17/13
to jquery-f...@googlegroups.com
Mr Alexander,

I Just got the upload working yesterday, I can tell you this, extract the zip file, and place the resulting folder into your webpage, you can rename it to "upload" or what ever. When you head over to www.yourpage.com/upload/ .. the default index.html file kicks in and and file uploaded will be placed into /upload/server/php/files/ .. at least that's what happened on my computer. I've tried changing the location of the uploads but it's futile. I'm still trying and I'll let you know once I get it done. When I changed any variables in main.js or the index.php inside /server/php/ I got errors like the above. So you might want to check if the upload works with defaults first before trying to change anything. :)
Reply all
Reply to author
Forward
0 new messages