ZF-10609: Zend_File_Transfer_Http_Adapater multiple files
Description
File upload problem.
Example:
form
5 files to upload.
When using Zend_File_Transfer_Adapter_Http(), the files will be uploaded when I select the 5 files. The moment I select less then 5 files, nothing will be uploaded.
Using move_uploaded_file, no problems ...
Code example
/** bug, only does upload when all files selected in form **/
/* $upload = new Zend_File_Transfer_Adapter_Http(); $upload->setDestination($path); $upload->receive(); */
foreach($files as $key => $file){ if(!empty($file['name'])){ $ext = substr($file['name'],-4); $ext = explode('.',$file['name']); $ext = end($ext); $naam = $key.$ext; move_uploaded_file($file['tmp_name'],$path.$naam); $params[$key] = $naam; }
I'm using Zend 1.10.8
Regards,
Ksaf
Comments
No comments to display