0
htmldoc.text

html tags are ignored. I want pretty print for html tags such as table , br.

What easy way are you using to do that?

dlis168
  • 21
  • 7

1 Answers1

0

I think you want beautiful soup.

from bs4 import BeautifulSoup
soup = BeautifulSoup(html_doc, 'html.parser')

print(soup.prettify())
CandleWax
  • 2,159
  • 2
  • 28
  • 46