recherche

Maison  >  Questions et réponses  >  le corps du texte

python 爬虫

tml = """
<div class="bd">
<p class>
hello

thank
</p>
"""

bs = BeautifulSoup(html, 'html.parser')
p = bs.find('p').string
print(p)

输出结果是 None为什么呢?

1.png

高洛峰高洛峰3058 Il y a quelques jours924

répondre à tous(1)je répondrai

  • 三叔

    三叔2016-10-22 16:12:59

    1.png

    可以获取hello thank啊,没有None


    répondre
    0
  • Annulerrépondre