yashirq's recent timeline updates
yashirq

yashirq

V2EX member #249573, joined on 2017-08-19 02:08:56 +08:00
yashirq's recent replies
@saximi find(name, attrs, recursive, string, **kwargs) href=True 指的是找 bsobj 下有 href 这个属性的 object ;取到第一个链接不是因为用[href'],而是因为 find ()返回的就是第一个 object,findall ()返回的所有包含 href 的 object ;取第二个链接可以用 find_next(),或者 findall(limit=2),可以看看官方文档的介绍 https://www.crummy.com/software/BeautifulSoup/bs4/doc/#find
return bsObj.find("div", {“ class ”:” Language_select ”}.find("a", href=True)['href']
About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2512 Online   Highest 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 16ms · UTC 05:08 · PVG 13:08 · LAX 22:08 · JFK 01:08
♥ Do have faith in what you're doing.