使用Simple HTML DOM重现100多个结果

时间:2015-11-16 18:39:19

标签: simple-html-dom information-retrieval

我使用以下代码从" PHP Simple HTML DOM"中提取搜索结果。

$url  = "http://www.google.com/search?      hl=en&safe=active&tbo=d&site=&source=hp&q={'$query'}&oq={'$query'}";

$html = file_get_html($url);
$linkObjs = $html->find('h3.r a');

但它返回最多10个结果无论如何从搜索中检索100个结果? 谢谢

1 个答案:

答案 0 :(得分:0)

在网址中使用num = 100参数,如此

$url  = "http://www.google.com/search?hl=en&safe=active&tbo=d&site=&source=hp&num=100&q={'$query'}&oq={'$query'}";