html 2 plain text

Fredrik Lundh fredrik at pythonware.com
Mon May 29 10:46:19 CEST 2006


garabik-news-2005-05 at kassiopeia.juls.savba.sk wrote:

> text=re.sub(r'(?s)\<.+?\>', '', html_text)
> (this will keep html entities, though)

here's a variation that handles that too:

     http://effbot.org/zone/re-sub.htm#strip-html

</F>




More information about the Python-list mailing list