People's Say
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '-40, 20' at line 14
SELECT t.topic_id, t.forum_id, t.forum_moved_id, t.topic_title, t.topic_poster, t.topic_views, t.topic_replies, t.topic_type,
t.topic_status, t.topic_icon, t.topic_vote, t.topic_first_post_id, t.topic_last_post_id, t.topic_rating,
t.topic_attachment,
p.post_id, p.post_username, p.post_time ,
u.user_id, u.username, u.user_allow_avatar, u.user_avatar,
lastposter.user_id AS lastpost_user_id, lastposter.username AS lastpost_username
FROM msf_posts p
LEFT JOIN msf_topics t ON (t.forum_id = 14 OR t.topic_type = 3 OR t.forum_moved_id = 14)
LEFT JOIN msf_users u ON u.user_id = t.topic_poster
LEFT JOIN msf_users lastposter ON lastposter.user_id = p.user_id
WHERE p.post_id = t.topic_last_post_id
ORDER BY t.topic_type DESC, t.topic_last_post_time DESC
LIMIT -40, 20