From b15c02c830e2a9c85c0dabcbe8f6f58c152dfbf8 Mon Sep 17 00:00:00 2001 From: Henrik Levkowetz Date: Tue, 12 Jun 2007 00:25:45 +0000 Subject: [PATCH] soup2html() tweak to handle table cells. - Legacy-Id: 326 --- ietf/utils/soup2text.py | 1 + 1 file changed, 1 insertion(+) diff --git a/ietf/utils/soup2text.py b/ietf/utils/soup2text.py index 6dde124eb..cda9e6ea8 100755 --- a/ietf/utils/soup2text.py +++ b/ietf/utils/soup2text.py @@ -106,6 +106,7 @@ def soup2text(html): # some preprocessing to handle common pathological cases html = re.sub("
[ \t\n]*(
)+", "

", html) html = re.sub("
([^\n])", r"
\n\1", html) + html = re.sub("(]*>)([^ \t\n])", r"\1 \2", html) soup = TextSoup(html) return str(soup)