<table border="7">
<tr>
<?php
foreach($colNames as $colName)
{
if ($colName == 'id')
{
}
else
{
echo "<th>$colName</th>";
}
}
?>
<th>Assign To</th>;
</tr>
<br />
<?php
foreach($data as $row)
{
echo "<tr>";
foreach($colNames as $colName)
{
//echo "<td>".$row[$colName]."</td>";
if ($colName == 'id')
{
}
else
{
echo "<td>".$row[$colName]."</a></td>";
}
}
?>
<td><select name="cs" id="cs">
<option value='0'>---Select One---</option>
<?php
$result = mysql_query("SELECT id, name FROM users");
while ($line = mysql_fetch_array($result))
{
echo '<option value="' . $line['id'] . '">' . $line['name'] . '</option>';
}
echo" </select></td>
</tr>
</table>";}?>