Thanks Vincent.
implode() works as you suggested. However I'm getting a "Supplied argument..." error.
$qfields=implode("," ,$field);
$query=mysql_query("select $qfields from $table where $where $compare $condition");
while ($row=mysql_fetch_row($query))
{
print"<tr>\n";
foreach ($row as $value)
{
print"<td width='200' align='center'><font size='1' face='arial'>$value</font></td>";
}
print"</tr>";
print"<tr><td colspan='$numfields'><hr></td></tr>";
}
Any suggestions? Thanks in advance!