View Single Post
Old 03-01-2018, 08:00 PM   #3
deback
Book E d i t o r
deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.deback ought to be getting tired of karma fortunes by now.
 
Posts: 432
Karma: 288184
Join Date: May 2015
Device: Laptop
Copy and paste the following line after every 600 characters;

<p class="chapter"><p>

Add the following to your .css file:

.chapter {
display: block;
margin: 3em 0;
page-break-after: always;
}

I would also combine all the html files that contain the text into one html file (right-click and choose merge files).

Then convert the file. Calibre will split the "text" html file into a bunch of html files, beginning with each of the <p class="chapter"></p> lines (the class "chapter" alerts conversion to split the file at that point). You really don't need the page-break-after: always; line in the .css file, but it won't hurt to include it. Conversion will delete that line during the conversion.

Last edited by deback; 03-01-2018 at 08:16 PM.
deback is offline   Reply With Quote