Can somebody please explain why this snippet of code is not working? I've tried multiple different ways of doing it but I can't seem to find a way to get it how I want it, i.e. - in a bordered table for each result.
//Get latest league results.
echo "<br /><br />";
echo "<h2>Latest Results</h2><br />";
$results = mysql_query("SELECT * FROM League_Index WHERE LeagueName='$leagueName' ORDER BY Timestamp DESC");
while($row = mysql_fetch_array($results))
{
echo "<table border='0' bgcolor='#DBB540'>"
echo "<tr>";
echo "<td><h4>" . $row['Result'] . "</h4></td>";
echo "<td><h4>" . $row['Comment'] . "</h4></td>";
echo "</tr>";
echo "</table>";
}
Also, what would be the best way of using a counter so that only the 5/10/etc. most recent entries are pulled out and displayed?
I'm grateful for any help you can offer.