Large file upload solution

巴扎黑
Release: 2016-11-09 11:15:41
Original
1062 people have browsed it

The traditional HTML method is no longer able to meet the needs of uploading very large files. Not to mention 100MB, 50MB is very large for the server. The service not only has to open a special link to wait for the file to be uploaded, but also allocates the same size of memory to save the file, which is quite stressful for the server.

In actual network environments, files of about 10MB generally need to be realized with the help of controls. On the one hand, it is because the domestic network environment is not stable, and on the other hand, it is due to the load of the server.

Like the oversized attachment upload function in QQ mailbox, the oversized attachment upload control in 115 Netdisk, Huawei Netdisk (DBank), and Kingsoft Express, they all use controls to implement the oversized file upload function.

They use the control to divide a large file, such as 1G, into many small pieces, each small piece is about 128KB, and then upload it in a loop until the upload is complete.

Every time the server receives a small piece, it is equivalent to receiving a separate file, which will be written directly to the hard disk. Finally, combine all accepted files.

The advantage of this is that it reduces the pressure on the server, improves the load capacity of the server, and allows the server to handle more user requests.

jQuery File Upload is a Jquery image upload component that supports multi-file upload, cancellation, deletion and breakpoint resumption, thumbnail preview before upload, list display of image size, support for upload progress bar display; supports various dynamic language development Service-Terminal.

Related labels:
php
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!