Code:
<?php
$counter_file = "./count.dat";
if(!($fp = fopen($counter_file, "r"))){
die ("Cannot open $counter_file.");
}
$counter = (int) fread($fp, 20);
fclose($fp);
$counter +=1;
echo "You're visitor No. $counter.";
$fp = fopen($counter_file, "w");
fwrite($fp, $counter);
fclose($fp);
?>
Is there any way out to change the Interger length[fread($fp, 20)] from bytes to mega bytes...so that hit counter of maximum number could be made.
thanx !
