Just get the string representation:
html_content = str(listing)
This is a non-prettified version.
If you want a prettified one, use prettify() method:
html_content = listing.prettify()
Just get the string representation:
html_content = str(listing)
This is a non-prettified version.
If you want a prettified one, use prettify() method:
html_content = listing.prettify()