Access logs - Keep accurate logs of a web page or folder section.
<? // Begin Access Log // == This Script Free To Use Providing This Notice Remains == // == This Script Has Been Found In The Free Public Codes Library == // == NOTICE: Though This Material May Have Been In A Public Depository, Certain Author Copyright Restrictions May Apply == // Place code at bottom of the page. $ip = getenv("REMOTE_ADDR"); $date = date("D, M n, h:ia"); $txtlog = "./log.txt"; // be sure to create a blank log.txt file $page = $_SERVER[PHP_SELF]; $fp = @fopen($txtlog, "r+") or die("Error occured while opening file."); $filedata = fread($fp, filesize($txtlog)); $mystr = "$ip - $date - $page $filedata" ; rewind($fp); fwrite($fp, $mystr); fclose($fp); ?> // NOTE: // Be sure to create a blank log.txt file for the access logs to be stored // You can create different log.txt files for pages... just rename $txtlog = "./log.txt