I was wondering if anybody knows how to simply mask a download, so users do not know where exactly they are downloading it from. That is all I want. Can somebody make me a simply script of some kind that I can do this? Thanks for any help!
Well there's nothing, 'simple' about it...I've done it using a heavily modified CGIProxy script, but its pretty bandwidth intensive...What are your needs, specifically..?
I use: $filePath = '/home/path/to/file.rar'; $fileTitle = 'Pie.rar'; //file will save as this value header('Content-Description: File Transfer'); header('Content-Type: application/force-download'); header('Content-Length: ' . filesize($filePath)); header('Content-Disposition: attachment; filename=' . str_replace(' ', '_', $fileTitle)); // Chunking function from php.net function readfile_chunked ($filename) { $chunksize = 1*(1024*1024); // how many bytes per chunk $buffer = ''; $handle = fopen($filename, 'rb'); if ($handle === false) { return false; } while (!feof($handle)) { $buffer = fread($handle, $chunksize); print $buffer; flush(); } return fclose($handle); } set_time_limit(0); readfile_chunked($filePath); PHP: