PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
<?php
// 'id' should be some unique key, i use the primary key of the table usually.
$countSql = "SELECT COUNT(id) FROM table";
$countQry = mysql_query($countSql);
$countAry = mysql_fetch_array($countQry);
$rows = $countAry[0];
if ($rows == 0) {
$title = 'There are no song on the list.<br/>Please wait the current DJ to approve your Song Request.<br/>Thank you!';
echo $title;
}
else {
// the first block of code pasted will go inside the else statement
}
?>
“Don’t worry if it doesn’t work right. If everything did, you’d be out of a job.” - Mosher’s Law of Software Engineering