chetansoni

IP logger Script - By h4ck0

Oct 2nd, 2013
5,173
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.76 KB | None | 0 0
  1. Script by CHETAN SONI
  2. --------------------------------------------------------------------
  3. <?php
  4. //Developed by Chetan Soni
  5. $file = "ips.txt";
  6. $f=fopen($file, 'a');
  7. fwrite($f,$_SERVER['REMOTE_ADDR']."\n");
  8. fwrite($f,$_SERVER['HTTP_USER_AGENT']."\n");
  9. fwrite($f,date('d-m-Y / H:i:s')."\n\n\n");
  10. fclose($f);
  11. ?>
  12. --------------------------------------------------------------------
  13. <?php
  14. //Developed by Chetan Soni
  15. $file = 'logfile.txt';
  16. $ipadress = $_SERVER['REMOTE_ADDR'];
  17. $date = date('d/F/Y h:i:s');
  18. $webpage = $_SERVER['SCRIPT_NAME'];
  19. $browser = $_SERVER['HTTP_USER_AGENT'];
  20. $fp = fopen($file, 'a');
  21. fwrite($fp, $ipadress.' - ['.$date.'] '.$webpage.' '.$browser."\r\n");
  22. fclose($fp);
  23. ?>
  24. --------------------------------------------------------------------
Advertisement
Add Comment
Please, Sign In to add comment