".number_format(dbcount("(post_message)", DB_POSTS, "post_author='".$user_data['user_id']."' AND forum_id IN (1, 2, 3)"))."
$result = dbquery(
"SELECT
tf.forum_name,tf.forum_id,
tt.thread_id,tt.thread_locked,tt.thread_subject,tt.thread_author,tt.thread_views,
tt.thread_lastpost,tt.thread_lastuser, tt.thread_postcount, tt.thread_lastpostid as last_id,
if(tt.thread_lastpost>$lastvisited,1,0) as new_post,
tu.user_id, tu.user_name as user_name,
tau.user_name as author,
tp.post_message, tp.post_smileys
FROM ".DB_THREADS." tt
INNER JOIN ".DB_FORUMS." tf USING(forum_id)
INNER JOIN ".DB_POSTS." tp USING(thread_id)
INNER JOIN ".DB_USERS." tu ON tt.thread_lastuser=tu.user_id
INNER JOIN ".DB_USERS." tau ON tt.thread_author=tau.user_id
WHERE ".groupaccess('forum_access')." AND tf.forum_id IN (11)
AND tt.thread_lastpostid = tp.post_id
ORDER BY tt.thread_lastpost DESC LIMIT ".($min + $max)
);
Category Forum
Modifications and Requests - 8Labels
None yet
Statistics
1 participant
Notifications
You are not receiving notifications from this thread.
Related Questions