📜  bs4 按名称查找元素 - 无论代码示例

📅  最后修改于: 2022-03-11 15:00:41.992000             🧑  作者: Mango

代码示例1
>>> from bs4 import BeautifulSoup
>>> soup = BeautifulSoup('')
>>> soup.find("meta", {"name":"City"})

>>> soup.find("meta", {"name":"City"})['content']
u'Austin'