ALTER TABLE cdb_threads ADD viewsid TEXT NOT NULL ;
global $delayviewcount, $supe_pushstatusadd, $timestamp, $tablepre, $tid, $db, $adminid
, $thread, $discuz_uid, $discuz_user, $viewsdateline, $viewsidnew, $dateformat, $timeformat, $timestamp, $timeoffset
$db->query("UPDATE LOW_PRIORITY {$tablepre}threads SET views=views+1 $supe_pushstatusadd WHERE tid='$tid'", 'UNBUFFERED');
if($discuz_uid && !eregi("$discuz_user", $thread[viewsid])) { //macaubbs瀏覽者記錄
$viewsdateline = gmdate("$dateformat $timeformat", $timestamp + $timeoffset * 3600);
$viewsidnew = AddSlashes($thread['viewsid']);
$viewsidnew .= " <option>$discuz_user $viewsdateline\n";
$db->query("UPDATE {$tablepre}threads SET viewsid ='$viewsidnew' WHERE tid='$tid'", 'UNBUFFERED');
}
if($discuz_uid && !eregi("$discuz_user", $thread[viewsid])) { //macaubbs瀏覽者記錄
<div id="ad_thread3_$post[count]"></div><div id="ad_thread4_$post[count]"></div>
<!--{if $post[number] ==1}-->
<select name="" align=right >
<option>瀏覽過本主題的會員</option>
$thread[viewsid]
</select>
<!--{/if}-->
<!--{if $post[number] ==1 && $discuz_uid}-->
<select name="" align=right >
<option>瀏覽過本主題的會員</option>
$thread[viewsid]
</select>
<!--{/if}-->
<!--{if $post[number] ==1 && ($forum['ismoderator'] || $post['authorid'] == $discuz_uid)}-->
<select name="" align=right >
<option>瀏覽過本主題的會員</option>
$thread[viewsid]
</select>
<!--{/if}-->
<!--{if $post[number] ==1 && $forum['ismoderator']}-->
<select name="" align=right >
<option>瀏覽過本主題的會員</option>
$thread[viewsid]
</select>
<!--{/if}-->
<!--{if $post[number] ==1 && $adminid==1}-->
<select name="" align=right >
<option>瀏覽過本主題的會員</option>
$thread[viewsid]
</select>
<!--{/if}-->
反安裝方法:
刪除數據
ALTER TABLE cdb_threads DROP viewsid
把上面的修改改回