441b1c3e5533d7fd4bb8dcee1e126af6c10d82c5
3 //Generic binary file downloading (when file exists)
5 $filename = r('f/'.$_GET['f']);
7 if (file_exists($filename)) {
8 header('Content-Description: File Transfer');
9 header('Content-Type: application/octet-stream');
10 header('Content-Disposition: attachment; filename='.basename($filename));
12 header('Cache-Control: must-revalidate');
13 header('Pragma: public');
14 header('Content-Length: ' . filesize($filename));
20 else header('Location: '.r('404'));