Disucz修改帖子查看数的方法·····刷新一次增加为N
时间:2021-07-01 10:21:17
帮助过:27人阅读
打开:在source\module\forum下,forum_viewthread.php打开,找到- C::t('forum_thread')->increase($_G['tid'], array('views' => $row['addviews']+1), true);
- discuz_process::unlock('update_thread_view');
- }
- }
- } else {
- C::t('forum_threadaddviews')->insert(array('tid' => $_G['tid'], 'addviews' => 1), false, true);
- }
- } else {
- C::t('forum_thread')->increase($_G['tid'], array('views' =>1), true, $tableid);
把上面代码里面的 3处 1 改成N(你想要的数值)
例如:- C::t('forum_thread')->increase($_G['tid'], array('views' => $row['addviews']+3), true);
- discuz_process::unlock('update_thread_view');
- }
- }
- } else {
- C::t('forum_threadaddviews')->insert(array('tid' => $_G['tid'], 'addviews' => 3), false, true);
- }
- } else {
- C::t('forum_thread')->increase($_G['tid'], array('views' =>3), true, $tableid);
|