beansandsausages Posted January 10, 2008 Share Posted January 10, 2008 Hey all. i have this query : $get_edit = mysql_query(sprintf("SELECT * FROM `news` ORDER BY id DESC LIMIT 0, 10 ")) or die('Error: ' . mysql_error()); while($edit = mysql_fetch_array($get_edit)) { $edit[msg] = str_replace($words, $faces, $edit['msg']); echo " <br /><br />$space <form action=\"test.php\" method=\"post\"><input type=\"checkbox\" name=\"id\" value=\"".$edit['id']."\"> ".$edit['id']." "; it works fine i was woundering is there a way if there no records for it to display none or some thing ? Link to comment https://forums.phpfreaks.com/topic/85350-think-this-is-right-boared/ Share on other sites More sharing options...
trq Posted January 10, 2008 Share Posted January 10, 2008 Take a look at mysql_num_rows(). Link to comment https://forums.phpfreaks.com/topic/85350-think-this-is-right-boared/#findComment-435493 Share on other sites More sharing options...
beansandsausages Posted January 10, 2008 Author Share Posted January 10, 2008 thank you. And sorry posted in wrong bored. Link to comment https://forums.phpfreaks.com/topic/85350-think-this-is-right-boared/#findComment-435526 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.