View Single Post
Old 09-30-2011, 02:25 PM   #3
therealjoeblow
Zealot
therealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfoldedtherealjoeblow reads XML... blindfolded
 
Posts: 106
Karma: 52102
Join Date: Jun 2010
Device: Samsung Android Tablet w/Moon+ Pro Reader
Convert it to .mobi first. If your headings are <h1> <h2> or <h3> and the text in the headings includes any of the words:chapter, part, epilogue, prologue, section or book; then the default structure detection will catch those and create a TOC at the end of the book (you can tweak the Xpath expression if it doesn't to to include the appropriate trigger words, or make it use various <p> classes instead to get the TOC created).

Then convert the .mobi back to HTMLZ, and you can then move the TOC part from the end to wherever you want it.

That's the simplest automatic method I've found.

Cheers
The REAL Joe
therealjoeblow is offline   Reply With Quote