if(!file_exists('./num.txt')){
touch('./num.txt');
}
$count = file_get_contents('./num.txt');
$count = $count?$count:0;
//push
echo 'you are '.$count.'bit people';
$count++;
$re=fopen('./num.txt','w');
fwrite($re, $count);
touch('./num.txt');
}
$count = file_get_contents('./num.txt');
$count = $count?$count:0;
//push
echo 'you are '.$count.'bit people';
$count++;
$re=fopen('./num.txt','w');
fwrite($re, $count);
fclose($re);
文件的小操作,呵呵