Jump to content

Nested While Loop


tjverge

Recommended Posts

I think the problem is with    echo "<td>".$row["countnow($i)"]."</td>"; it's not showing anything, any ideas how to fix it?

$i = 1;
While ($i <25)
{
?>
  <tr>
    <td><?php echo $i; ?></td>
    <?php 
$sql = "SELECT * FROM `systems` WHERE `solarSystemName` LIKE $sname" or die (mysql_error());
$result = mysql_query($sql);
while ($row = mysql_fetch_array($result)){
    echo "<td>".$row["countnow($i)"]."</td>";
}
?>
<tr>
<?php
$i++;
}

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.