I'm currently doing this:
$query = "select column from table order by field desc";
$result = mysql_query($query);
while ($row = mysql_fetch_array($result)) { echo "<tr>
<td BGCOLOR=black><font color=lightblue size=2 face=verdana>$row[9] </td></font>
<td bgcolor=black><font color=orange face=verdana size=2> $row[1] </td></font>
<td bgcolor=black><font color=lightgreen face=verdana size=2>$row[2] </td></font>
<td bgcolor=black><font color=lightyellow face=verdana size=2> $row[8] </td>
</font></tr>";
}
mysql_free_result($result);?>
...and it takes a long time if I have more than a few hundred records in the table. Is there a faster way of doing it like buffering instead of echo'ing with every loop?
Any pointers on optimization of the table and the code are welcome.