J
|
Jane 1/29/2007 |
Hi,
and replace it with this one: $strSQL.=" limit 49";
LogInfo($strSQL); and add following code just before: $str1 = "select count(*) from ".$strTableName." ".substr($strSQL,strpos($strSQL,"where")); $str2 = substr($strSQL,0,strpos($strSQL,"where")); $rs = db_query($str1,$conn); $data = db_fetch_numarray($rs); if ($data[0]>50) {$strSQL=$str2." where 1=0"; ?><script> alert("please refine your search. too many results!"); </script><?php } |