anyone know why this script doesnt seems to display all the rows (suppose to be 7 rows) instead it display only 1
SQL code is correct as i check with phpmyadmin and database connect is also correct.
$select="SELECT Id, Name, Support, Price FROM Product WHERE Category = 'gfx'";
$result=mysql_query($select);
echo "<br>" . $result . "<br>";
if(!result) { echo "problems"; }
?>
<table width="69%" align="center">
<tr valign="top">
<td width="20%"></td>
<td width="69%"><strong>Motherboard Types</font></strong></td>
<td width="11%"><strong>Price</font></strong></td>
</tr>
<form name="form1" method="post" action="man3.php">
<?
$count = 0;
while(list($Id, $Name, $Support, $Price) = mysql_fetch_row($result)) {
//echo $Id . " : " . $Name . " : " . $Support . " : " . $Price . " <br> ";
if($count == 0) {
?>
<tr valign="top">
<td width="20%"><div align="right">
<input type="radio" name="c_id" value="<?=$Id?>" checked>
</div></td>
<td width="69%"><?=$font?><?=$Name?></font></td>
<td width="11%"><?=$font?>$<?=$Price?></font></td>
</tr>
<?
$count = 1;
} else {
?>
<tr valign="top">
<td width="20%"><div align="right">
<input type="radio" name="c_id" value="<?=$Id?>">
</div></td>
<td width="69%"><?=$font?><?=$Name?></font></td>
<td width="11%"><?=$font?>$<?=$Price?></font></td>
</tr>
<?
}
}
mysql_close( );
?>
<tr valign="top">
<td width="20%"></td>
<td width="69%"> <div align="right">Total: </div></td>
<td width="11%">$<?=$total_price?></td>
</tr>
<tr valign="top">
<td width="20%"></td>
<td width="69%"><center><input type="submit" name="Submit" value="Select Memory"></center></td>
<td width="11%"></td>
</tr>
</form>