<? include("config.inc.php"); mysql_connect(localhost,$username,$password); @mysql_select_db($database) or die( "Unable to select database"); $query="SELECT * FROM vand_chatlog"; $result=mysql_query($query); $num=mysql_numrows($result); mysql_close(); echo "<title>Vandagard Chatlog</title."; echo "<b><center>Recently heard on Vandagard..</center></b><br><br>"; $i=0; while ($i < $num) { $time=mysql_result($result,$i,"time"); $channel=mysql_result($result,$i,"channel"); $who=mysql_result($result,$i,"who"); $text=mysql_result($result,$i,"text"); echo "$time $channel $who : $text<br>"; $i++; } ?>