Beautiful soup : why does "string" not give me the string?

  • Thread starter Gabriel Rossetti
  • Start date
G

Gabriel Rossetti

Hello everyone,

I am using beautiful soup to parse some HTML and I came across something
strange.
Here is an illustration:
u'hello \xe7a boume'

why does soup.find("div", "text").string not give me the string? Is it
because there is a <br/>? Is there a way to have it ignore the <br/>
tag? Am I doing something wrong?

Thank you,
Gabriel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,776
Messages
2,569,603
Members
45,189
Latest member
CryptoTaxSoftware

Latest Threads

Top