עשיתי:
PHP קוד:
$query = @mysql_query("SELECT name, Count(*) FROM table WHERE name Like '%$q%'");
$r = mysql_fetch_array($query);
$query_count = $r['name'];
$query_count = strip_tags($query_count);
echo " There's <b>" . $query_count . "</b> results for the query <b>" . $q . "</b>.\n";
תוצאה:
קוד:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /hsphere/local/home/catdance/royalgames.3dfaculty.com/digital/search.php on line 18
There's results for the query d.