来自 this question我已经学会了如何使用 Python 3 进行谷歌搜索。但是在给出的示例中,您只能检索前 4 个结果。我需要检索有关前 25 个结果的信息(至少)。
对于每个结果,我希望能够得到:
- 标题
- 网址
- 可见url(http://en.wikipedia.org/wiki/Information_retrieval的可见url为http://en.wikipedia.org/)
- 网站描述
我该怎么做?
编辑:我正在使用 Python 3.1
最佳答案
This thread应该告诉你你需要知道什么。简而言之,将 &rsz=large
添加到 URI 以一次获得八个结果,而 &start=8
(或 16、24 等)让您的结果以指示的数字。在任何情况下都不能超过 64 个,有些搜索只允许 8 个。
关于python - 使用 Python 进行谷歌搜索,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4082714/