在帖子表pre_forum_thread中沒有是否置頂或置頂?shù)燃?jí)的字段,用的是displayorder(顯示順序)。
displayorder = 1 本版置頂
displayorder = 2 分類置頂
displayorder = 3 全局置頂
例如,在任意頁面調(diào)用全站置頂數(shù)據(jù)時(shí)
<!--{eval $tops = DB::fetch_all("SELECT tid,fid,subject,dateline,author,authorid FROM ".DB::table('forum_thread')." WHERE `displayorder` = '3' ORDER BY `dateline` LIMIT 0,10");}-->