How to show number results found for search query in my site? http://search.yahoo.com/search;_ylt=A0geutkDOWxLDoUBfbVXNyoA?p=site:mixx.com+linkdomain:cnet.com
<?php preg_match("/<strong id=\"resultCount\">([0-9,]*)<\/strong> results for<\/span>/", file_get_contents("http://uk.search.yahoo.com/search?p=site:mixx.com+linkdomain:cnet.com"), $matches); echo $matches[1]." Results"; ?> PHP:
Im not familiar with the Yahoo API, but here is a more clear version of the code I posted. <?php $query = "site:mixx.com+linkdomain:cnet.com"; preg_match("/<strong id=\"resultCount\">([0-9,]*)<\/strong> results for<\/span>/", file_get_contents("http://uk.search.yahoo.com/search?p=".$query), $matches); $numberofresults = $matches[1]; echo $numberofresults; ?> PHP:
Please help me How to add Yahoo API code to this code? <?php $query = "site:mixx.com+linkdomain:cnet.com"; preg_match("/<strong id=\"resultCount\">([0-9,]*)<\/strong> results for<\/span>/", file_get_contents("http://uk.search.yahoo.com/search?p=".$query), $matches); $numberofresults = $matches[1]; echo $numberofresults; ?> Code (markup):