Skip to content

Instantly share code, notes, and snippets.

Created August 10, 2017 07:17
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
Function pour récupérer le nombre de résultats Google (FR)
function get_search_num($keyword){
$url = sprintf('', $keyword);
$data = file_get_contents($url);
$pattern = sprintf(
preg_match_all($pattern, utf8_encode($data), $matches);
return trim($matches[1][0]);
// utilisation
echo get_search_num('seo');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment