View Single Post
Old 01-15-2011, 08:44 AM   #14
ldolse
Wizard
ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.
 
Posts: 1,337
Karma: 123455
Join Date: Apr 2009
Location: Malaysia
Device: PRS-650, iPhone
The default settings will only split on H1 and H2 tags. It won't auto-magically put the chapters in a TOC. For that you need the right xpath.

That's why I told you to change the 'Detect Chapters at(Xpath expression).

Change it from the default to this:
Code:
//*[((name()='h1' or name()='h2') and re:test(., '\d+', 'i')) or @class = 'chapter']
And if you can't figure out Xpath for other files just open the file in Sigil and re-save it after using the pre-process option, you'll automatically get a TOC.

In the future use Calibre's bug reporting system if you have a file that you think doesn't work.
ldolse is offline   Reply With Quote