Guest User

Untitled

a guest
Feb 16th, 2019
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. if($_POST['downloadfile']) {
  2. $downloadfile = $_POST['downloadfile'];
  3. header("Cache-Control: public");
  4. header("Content-Description: File Transfer");
  5. header("Content-Disposition: attachment; filename= $downloadfile");
  6. header("Content-Transfer-Encoding: binary");
  7.  
  8. @readfile($downloadfile);
  9. exit;
  10. }
  11.  
  12. header("Content-Disposition: attachment; filename= basename($downloadfile"));
Add Comment
Please, Sign In to add comment