【发布时间】:2017-07-17 20:09:45
【问题描述】:
我正在尝试使用 BeautifulSoup 从页面中获取结果:
req_url = 'http://www.xscores.com/soccer/livescores/25-02'
request = requests.get(req_url)
content = request.content
soup = BeautifulSoup(content, "html.parser")
scores = soup.find_all('tr', {'style': 'height:18px;'}, limit=None)
print(len(scores))
>50
我阅读了以前的解决方案:Beautiful Soup findAll doen't find them all 我尝试了 html.parser、lxml 和 html5lib,但没有一个返回超过 50 个结果。有什么建议吗?
谢谢
【问题讨论】:
标签: python beautifulsoup lxml html5lib