Hey there. I am a little lost here, trying to make a simple PHP script.

I made a MySQL table called "reviews" with the fields "rID" and "title". I inserted one row (rID 1 and title Gladiator).

I made the following SQL command in reviews.php :


$sql = mysql_query("SELECT title FROM reviews WHERE rID = $rID");
if (!$sql) {
echo("Error retrieving data!");
exit();
} ?>


Now I want the title to show up between the <TITLE> tags, so I made this:

<TITLE>My Site - Reviews - <? echo $title ?></TITLE>

It doesn't work. What am I doing wrong? (I know it must be something stupid =)