How to get large files from url with php and buffer it out to user?

???

New member
How can php get large files from url and directly "process" and upload to user? I mean output buffering.

I have this for now but its not working. And btw I got output buffering enabled on php.ini!

<?php


ob_start();



header('Content-Disposition: attachment; filename="downloaded.zip"');
$source = fopen("http://download.thinkbroadband.com/1GB.zip","r");
while ($a = fread($source, 4096)){

echo $a;
ob_flush();
flush();

}
fclose($source);


?>
 
Back
Top