Parse TOC correctly with new layout

This commit is contained in:
rdb 2010-01-02 14:37:04 +00:00
parent 8011302cef
commit 4c7c0b4b68

View File

@ -120,7 +120,7 @@ def parseManualTOC(filename):
filename = open(filename)
text = filename.read()
filename.close()
text = text.split("<h2>Table of Contents</h2>")[1].split("</td>")[0]
text = text.split("<h2>Table of Contents</h2>")[1].split("</div>")[0]
text = "<root>" + text.replace("<li>", "") + "</root>"
text = re.sub(re.compile("<!--([^>]+)>"), "", text)
result = []