… короче, примерно так:
ПОСЛЕ $posts = array(); (стр 519)
ВСТАВИТЬ
if($page>1){ $post1 = "SELECT p.*, u.id as uid, u.nickname author, u.login author_login, u.is_deleted deleted, up.imageurl imageurl, up.signature signature FROM cms_forum_posts p LEFT JOIN cms_users u ON u.id = p.user_id LEFT JOIN cms_user_profiles up ON up.user_id = u.id WHERE p.thread_id = '$id' ORDER BY p.pubdate ASC LIMIT 1"; $post1result = $inDB->query($post1); $p = $inDB->fetch_assoc($post1result); $p['content'] = $inCore->parseSmiles($p['content'], true); $posts[] = $p; }