ip.phpCode:
<?php
$ip = $_SERVER['REMOTE_ADDR'];
$date = date("d F Y : H:i:s");
$file = "ip.txt";
$a = fopen($file, "a");
fwrite($a, "Time: $date IP Adress: $ip \n");
?>
Sada na stranicama na kojima zelite da se snima IP kada neko udjete dodate u kod:Code:
<?php
include "ip.php";
?>