Setting Multiple Variables with php and MySQL
===

So I have a code I want to use

    mysql_select_db("website", $con);
    	$result=mysql_query("SELECT * FROM characters where online='1'");
    	while ($row=
    				mysql_fetch_array($result))
    				{
    				echo $row['name'];
    				}
    				if ($row['race'] == "1");
    				{
    				echo '<img src="img/8-0.gif" />';
    				}
    				if ($row['class'] == "3");
    				{
    				echo '<img src="img/3.gif" ?>';
    				}
    			mysql_close($con);
    		?>

Now I only wanted the two images to show if the online field was 1, but they show no matter what. Does anyone know how I can fix this? Thanks.