这样判断:if (mysql_num_rows($result) < 1) echo '记录集为空';elseecho '有结果';这里写在js中判断if(mysql_num_rows($result) >= 1)