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

Untitled

By: a guest on Aug 21st, 2012  |  syntax: PHP  |  size: 0.26 KB  |  hits: 24  |  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. $file = '../downloads/Patch_D2.mpq';
  2. $txt = $file . '.txt';
  3. if ($_GET['page'] == 'downloads?file=patch')
  4. {
  5. if(!file_exists($txt)){
  6. file_put_contents($txt, '0');
  7. }
  8. file_put_contents($txt, ((int) file_get_contents($txt)) + 1);
  9. header("Location: $file");
  10.   die;
  11. }