web/privatedoc/download.php
changeset 7 7a5d38af0e65
equal deleted inserted replaced
6:06c4f682b7b2 7:7a5d38af0e65
       
     1 <?php
       
     2 $file=$_GET['file'];
       
     3 
       
     4 header("Content-disposition: attachment; filename=".$file);
       
     5 header("Content-Type: application/force-download");
       
     6 header("Content-Transfer-Encoding: binary"); 
       
     7 header("Content-Length: ".filesize("/home/www/documents/audio/".$file));
       
     8 header("Pragma: no-cache");
       
     9 header("Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0");
       
    10 header("Expires: 0");
       
    11 readfile("/home/www/documents/audio/".$file);
       
    12 exit();
       
    13 ?>