if(!isset($_COOKIE['RSVcount'])) { $value="Counter"; setcookie("RSVcount", $value, time()+(60*30), "/"); } $datei = fopen("../besucher.txt", "r+"); $counterstand = fgets($datei, 10); if($counterstand == "") $counterstand = 0; if($value=="Counter") { $counterstand++; rewind($datei); fwrite ($datei, $counterstand); } fclose ($datei); ?>