I am having trouble getting the results from my query to display all of the records. The code I have displays everything accept the first result of the query. Can someone take a look at my code and offer suggestions. Thank you. It works correctly at the console.
$query = "SELECT * from providerinfo,team where providerinfo.module=team.teamnumber order by providerinfo.module, providerinfo.lastname, providerinfo.firstname";
$result = mysql_query($query);
$name_row = mysql_fetch_array($result);
while ($name_row = mysql_fetch_array($result)) {
print ("
<div align=center>
<table width = 35% cellspacing=0 cellpadding=0 border=0>
<tr>
<td width = 20%>$name_row[1], $name_row[2]</td>
<td width = 10%>$name_row[3]</td>
<td width = 5%>$name_row[7]</td>
</tr>
</table>
</div>
");