參考連結:http://www.phpbbhacks.com/viewhack.php?id=967
參考網站:http://yll.loxa.edu.tw/phpBB2/viewforum.php?f=15
安裝程式 : MySQL 4.0.18-standard
狀況描述: 當我安裝了Shop Mod 後, 想閱讀主題時, 一按主題後就出了:
Could not obtain post/user information.
DEBUG MODE
SQL Error : 1064 You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM phpbb_posts p, phpbb_users u, phpbb_posts_text pt WHERE p
SELECT u.*, p.*, pt.post_text, pt.post_subject, pt.bbcode_uid, u.user_items, u.user_privs, u.user_effects, FROM phpbb_posts p, phpbb_users u, phpbb_posts_text pt WHERE p.topic_id = 3 AND pt.post_id = p.post_id AND u.user_id = p.poster_id ORDER BY p.post_time ASC LIMIT 0, 10
Line : 464
File : /home/mos/public_html/phpBB2/viewtopic.php
Line 453~465
代碼: 選擇全部
$sql = "SELECT u.*, p.*, pt.post_text, pt.post_subject, pt.bbcode_uid, u.user_items, u.user_privs, u.user_effects,
FROM " . POSTS_TABLE . " p, " . USERS_TABLE . " u, " . POSTS_TEXT_TABLE . " pt
WHERE p.topic_id = $topic_id
$limit_posts_time
AND pt.post_id = p.post_id
AND u.user_id = p.poster_id
ORDER BY p.post_time $post_time_order
LIMIT $start, ".$board_config['posts_per_page'];
$cm_viewtopic->generate_columns($template,$forum_id,$sql);
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, "Could not obtain post/user information.", '', __LINE__, __FILE__, $sql);
}究竟出了甚麽問題呢? 請指教





