I've used the file_get_contents to get the google results of a string and display to the web page.
$url = "http://www.google.com/search?q=".$str;
$result = file_get_contents($url);
echo $result;
But is it possible to display only the first few results, say 5, instead of all the results ?