Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 4th, 2012  |  syntax: None  |  size: 0.67 KB  |  hits: 13  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. if (file_exists($f)) {
  2.             print 'size = '.filesize($f).'|';
  3.             //return;
  4.             header('Pragma: no-cache');
  5.             header('Expires: 0');
  6.             header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
  7.             header('Last-Modified: '.gmdate('D, d M Y H:i:s', filemtime($f)).' GMT');
  8.             header('Content-Type: application/zip');
  9.             header('Content-Disposition: inline; filename="'.basename($f).'"');
  10.             //header('Content-Transfer-Encoding: binary');
  11.             header('Content-Length: '.filesize($f));
  12.  
  13.             header('Connection: close');
  14.             readfile($f);
  15.             exit();
  16.         }