例:
输出<span class="w-txt">分享</span>中的文本”分享“
contents = bsObj.find_all("span",{"class":"w-txt"})
for content in contents:
print(content.get_text())
例:
输出<span class="w-txt">分享</span>中的文本”分享“
contents = bsObj.find_all("span",{"class":"w-txt"})
for content in contents:
print(content.get_text())