0

i am using read file function to allow users to download files through a php page and i am blocked direct access to files with htaccess.but the problem is the files can't be downloaded with download managers like IDM and it says:"This site doesn't allow you to request twice for file ". i am looking for a way to output the file to user and also let him use download managers!

tshepang
  • 12,111
  • 21
  • 91
  • 136
  • are you blocking the file from being downloaded more than once? The download manager likely makes a separate request for the file. You also might need to implement something like the http range header to allow partial file downloads which would allow multiple connections to the same file. – Jonathan Kuhn Sep 24 '14 at 18:26
  • i know it make a separate request but i don't know how to allow it!how can i implement range header and how doest it work? – user2635676 Sep 24 '14 at 18:27
  • Don't forget to write and close any session you have started before reading file... – Loenix Sep 25 '14 at 20:48
  • For explainations of the range header see http://www.media-division.com/the-right-way-to-handle-file-downloads-in-php/, and for an EXAMPLE download script http://www.media-division.com/php-download-script-with-resume-option/ – Chris Sep 25 '14 at 20:58

0 Answers0