from bs4 import BeautifulSoup
import requests
web_url = r'https://www.mlb.com/scores/2019-05-12'
get_web = requests.get(web_url).text
soup = BeautifulSoup(get_web,"html.parser")
score = soup.find_all('div',class_='container')
print(score)
我想找到this
但结果是this
Tags:
向API发送标题,告诉它“嘿,我是桌面浏览器”,以便从服务器端获得相同的HTML:
有用的链接:
相关问题 更多 >
编程相关推荐