View Single Post
Old 01-09-2011, 07:54 AM   #13
cybmole
Wizard
cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.
 
Posts: 3,720
Karma: 1759970
Join Date: Sep 2010
Device: none
i have another challenging book - there are chapters, within PARTS & the defaults only added PARTS to TOC.

I tried multiple hacks & eventually got chapter numbers without parts by telling xpath to look only for \d+ values, but lost / reformatted the PARTS code somewhere along the way.

when first converted (from a LIT source ) both the parts & the chapter numbers had h2 tags but detecting all h2 stubbornly refused to work.
but I cannot get both parts & chapters whatever I try ???

relevent code lines in my epub - after much to & fro between epub & mobi, now looks like
:
Code:
 <p class="calibre2"><span class="calibre4"><span class="bold">Part I</span></span></p><a class="calibre3"></a>
<p class="calibre2"><span class="calibre4"><span class="bold">9</span></span></p>
that is for part 1 and for chapter 9 as examples. what do I need in the chapter detection xpath to get both ?

I have tried a regex of \d*|Part I in the xpath wizard ,with class bold, but no joy. it finds all the chapter numbers but not the Part I, Part II etc.

If I go all the way back to lit, what can I add to default chapter detection so that it looks for stand-alone numbers as well as for part, section, chapter etc

Last edited by cybmole; 01-09-2011 at 08:16 AM.
cybmole is offline   Reply With Quote