My problem is the following code the comment&rating area of the array should have a comment in it as the DB history table does ...?
SELECT users.uid, users.username, history.user_id, history.comment, history.rating
FROM history
LEFT JOIN users
ON users.uid=history.user_id
WHERE history.book_id="$bid"
It returns :
Array ( [uid] => 3 [username] => Reign [user_id] => 3 [comment] => [rating] => )
mysql_*functions in new code. They are no longer maintained and are officially deprecated. See the red box? Learn about prepared statements instead, and use PDO or MySQLi - this article will help you decide which.="$bid"either. That's a SQL injection mistake. Should change to=:bid.