Zf2 file upload by jQuery File Upload - file was not found

最后都变了- 提交于 2019-12-08 01:56:40

问题


when I use jQuery File Upload I have error during ajax upload.

In controller:

$adapter = new \Zend\File\Transfer\Adapter\Http();
$adapter->isValid();

or

$adapter->receive();

Both methotds returns "File [file name] was not found"

dump from $_FILES:

Array
(
    [files] => Array
        (
            [name] => Penguins.jpg
            [type] => image/jpeg
            [tmp_name] => /tmp/phpwQoG2L
            [error] => 0
            [size] => 777835
        )

)

If I use move_uploaded_file in the same place all works

ZF2 v2.2.4

What is wrong?

来源:https://stackoverflow.com/questions/19616982/zf2-file-upload-by-jquery-file-upload-file-was-not-found

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!