Here is my php code. Where did I go wrong?

Here is the php code i am using, but it doesn't work.
The idea was to have 4 results then stop.

<?php

include 'database_conn.php'; // make db connection

$result = mysql_query( "SELECT * FROM rugs;")

or die("SELECT Error: ".mysql_error());

print "<table width=100% border=0>\n";

while ($get_info = mysql_fetch_row($result)){
print "<tr>\n";

foreach ($get_info as $field)

$i=1;
while($i<=4)
{
print "\t<td><font face=arial size=2/>$field</font></td>\n";
print "</tr>\n";
$i++;
}

print "</table>\n";

?>
 
Back
Top