📄 hitupdate.php
字号:
<?php
!function_exists('readover') && exit('Forbidden');
if(file_exists(D_P."data/bbscache/hits.txt")){
if($hitsize<5120){
$hitarray=explode("\t",readover(D_P."data/bbscache/hits.txt"));
P_unlink(D_P."data/bbscache/hits.txt");
$hits=array_count_values($hitarray);
$count=0;
foreach($hits as $key=>$value){
if($key){
$db->update("UPDATE pw_threads SET hits=hits+'$value' WHERE tid='$key'");
}
$count++;
if($count>300) break;
}
$nowtime=($timestamp-$tdtime)/3600;
$hit_control=floor($nowtime/$db_hithour)+1;
if($hit_control>24/$db_hithour)$hit_control=1;
$db->update("UPDATE pw_bbsinfo SET hit_control='$hit_control',hit_tdtime='$tdtime' WHERE id=1");
}else{
P_unlink(D_P."data/bbscache/hits.txt");
}
}
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -