mysql help
hi, here is my code... i think something is wrong with it... please help me identify wat's the problem thanks
<?php // process information in body.
// Retrieve information in the head section
$query="SELECT * from imageTable";
$result = mysql_query($query) or die ("Error opening imageTable");
if (mysql_num_rows($result) == 0) {
echo "No rows found, nothing to print so am exiting";
exit;
} else {
echo "Number of rows: ".mysql_num_rows($result).;
echo "Number of fields:".mysql_num_fields($result).;
}
while($row = mysql_fetch_assoc($result))
{
echo $row;
foreach($row as "$key" >= "$value")
{
echo "$value";
}
}
mysql_free_result($result);
?>
===================================
output
===================================
= "$value") { echo "$value"; } } mysql_free_result($result); ?>
===================================
this happen after the ">"sign.. is the syntax wrong or wat???
please answer asap thanks
|