I have created a table using information from my database which all works fine. I have this all echo'd back in position how i want it.
My question is when i add a background to this, it adds a background to everything in every row. How can i add a background to each row with maybe 10px padding in between each background?
echo "
<table id=\"messageboard\" cellpadding=\"0\" cellspacing=\"0\">
";
echo "<tr><th width=\"150px\" style=\"text-align: center;\"></th>
";
echo "<th width=\"330px\" style=\"background-color: #c01718;\"></th>
";
echo "</tr>";;
while($row = mysql_fetch_array($result)){
echo "<tr><td>
";
echo $row ['username']."<br />".$row ['date_time'];
echo "<td>
";
echo $row ['message'];
echo "</td></tr>
";
}