File Upload Large Files PHP/AJAX [closed]

扶醉桌前 提交于 2021-02-07 14:16:44

问题


Im trying to find some software to help me upload really large files (>200mb). I only want to upload a single file, no multi-options. Also i would like a simple progress bar if possible.

I have come across http://pixeline.be/experiments/jqUploader/ which is literally what i need but it has a limit of 100mb per file, because it uses flash.

Does anyone know of something else thats similar to this, but can handle larger files?

thx


回答1:


Another popular solution is http://www.swfupload.org/, but I guess it may suffer from the 100MB limit.

Regarding the whole issue of large file sizes, from my research it seems that in order to upload large files there is no other option than to increase the values for upload_max_filesize, post_max_size and max_execution time. I just wonder what the security implications are of having post_max_size set to, say, 500M? Its not the issue of bandwidth that concerns me - it is the possible DoS attacks that might arise from allowing attackers to send random 500M POST requests to the server. The best workaround I can think for this issue is to send uploads to a different server.

There is a good discussion of the whole issue here:

http://aaronwinborn.com/blogs/aaron/how-handle-large-file-uploads

If any Apache hackers out there can shed any light on the security implications of having a really large value for post_max_size that would be great.




回答2:


You can try using HTML5 and AJAX to handle large file uploads. In a combination with PHP streams you'll get very low memory usage. Here a link with more details:

http://www.webiny.com/blog/2012/05/07/webiny-file-upload-with-html5-and-ajax-using-php-streams/




回答3:


I would recommend implementing a Java uploader, like JumpLoader and integrate it with your current system. It has extensive API and its JScript interface is easily accessibly as well. You can, as I did, code your server side handler and make it capable of:

  1. Multiple file uploading
  2. Uploads without any limits in filesize - I am currently struggling with PHP's 2G limit on fopen(), but I expect to solve soon
  3. Partitioned uploading - file gets uploaded in chunks
  4. Transmission integrity - JumpLoader can also calculate and send md5 checksums for every partition and the whole file itself, which you can validate in server side to see whether the package arrived ok or not.

Hope it helps.




回答4:


Perhaps http://www.uploadify.com



来源:https://stackoverflow.com/questions/3562274/file-upload-large-files-php-ajax

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