LEFT JOIN ".DB::table("forum_post")." p on p.tid=t.tid
LEFT JOIN ".DB::table("forum_forum")." f on f.fid=t.fid
WHERE DATE_SUB(CURDATE(), INTERVAL $day DAY) <= FROM_UNIXTIME(t.`dateline`, '%Y-%m-%d') AND t.`fid` not in ($fids) $_digest and t.displayorder>=0 and p.first=1 and t.isgroup = '1'