Try this... <? session_start(); if ( ! isset($_SESSION['been_here_before']) ) { $_SESSION['been_here_before']=TRUE; $fp=fopen("./counter.txt","r"); $count=fread($fp,5); fclose($fp); ++$count; $fp=fopen("./counter.txt","w"); fwrite($fp,$cnt); fclose($fp); } print "Visited: .$count.<BR>"; ?>
-----Original Message----- From: Radovan Radic [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 30, 2003 1:06 PM To: [EMAIL PROTECTED] Subject: [PHP-WIN] Re: Counter problems! Yes, but what if you refresh the page? Or type in the address bar index.php and press enter, i think it will be increased? Radovan -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php