Hi all,
If you look at the script below how can i get the form to display if the confirm_cat is equal to "nil"?
At the moment it only displays when confirm_cat isn't equal to 'yes'.
Any ideas?
Cheers,
micmac
<?
$row = mysql_fetch_row(mysql_query("SELECT COUNT(*) FROM cat1 WHERE CatParent = $id"));
if($row[0] > 0){
$result = mysql_query("SELECT * FROM cat1 WHERE CatParent = $id AND active='yes' ORDER BY CatName");
while($row = mysql_fetch_array($result)){
if($row['confirm_cat'] == 'yes'){
echo "<center><TABLE width=\"400\"></center><TR><td>";
echo "<p align=\"left\"><a href=\"add_url1.php?id={$row['CatID']}&country=$country\">{$row['CatName']}</a></p>";
echo "</TR><center></table></center>"; }
}
} else {
?>
<form method="post" action="<?php echo $PHP_SELF?>">
HTML form here.............
</form>
<?
}
}
?>