Created
May 2, 2018 14:08
-
-
Save antistereotip/24f814f77917d68df0f7022d9273af88 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* counter */ | |
//opens countlog.txt to read the number of hits | |
$datei = fopen("./countlog.txt","r"); | |
$count = fgets($datei,1000); | |
fclose($datei); | |
$count=$count + 1 ; | |
echo "<p>$count" ; | |
echo " hits</p>" ; | |
echo "\n" ; | |
// opens countlog.txt to change new hit number | |
$datei = fopen("./countlog.txt","w"); | |
fwrite($datei, $count); | |
fclose($datei); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment