Hi, I have a error message when I try and execute the following code
$ccid = cleanQuery($_SESSION['cid']);
$ip = $_SERVER['REMOTE_ADDR'];
$today = date('Y-m-d');
// check to see how many entries in the tbllog have already been entered
$qry5 = mysql_query("SELECT count(id) AS total FROM tbllog WHERE cid=$ccid AND action='EMAIL_REFER' AND datetime LIKE'$today%' GROUP BY ipaddress");
//echo $num_email = mysql_num_rows($qry5);
$row3 = mysql_fetch_array($qry5);
$num_email = $row3['total'];