\n"; print "\nProduct IDProduct NameProduct Price\n\n"; while ($x < mysql_numrows($result)) : $id = mysql_result($result, $x, 'prod_id'); $name = mysql_result($result, $x, 'prod_name'); $price = mysql_result($result, $x, 'prod_price'); print "\n"; print "$id\n$name\n$price\n"; print "\n"; $x++; endwhile; print ""; mysql_close(); ?>