Skip to content
Advertisement

secure and resume support file downloading with php

I want to give permission to some of my website users to download a specific file. the download needs to be resume support just for user convenience.

For that reason it came to my mind to secure the file with this piece of code:

JavaScript

the problem is that not only it’s not resume support also it’s gonno give my webserver a big overhead and also a lot of memory needed for file_get_contents for large files also for files bigger than 134217728 bytes you will get this error message:

Allowed memory size of 134217728 bytes exhausted (tried to allocate 188862464 bytes)

Any suggestions?

Advertisement

Answer

Check this related question: Is there a good implementation of partial file downloading in PHP?

User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement