View Single Post
Old 03-17-2013, 03:32 PM   #1
BobC
Addict
BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.
 
Posts: 343
Karma: 245756
Join Date: Dec 2008
Location: Lancashire, U.K.
Device: BeBook 1, BeBook Pure, Kobo Glo, Various Android Apps
ODT -> Epub odd css behaviour

I've been converting a few ODT files I have to EPUB using Calibre.

One oddity I noted was that in at least one book the HTML in one chapter pointed to the stylesheets at :

Code:
<link href="stylesheet.css" rel="stylesheet" type="text/css"/>
<link href="page_styles.css" rel="stylesheet" type="text/css"/>
While the remainder (correctly) pointed to :

Code:
<link href="../Styles/stylesheet.css" rel="stylesheet" type="text/css"/>
<link href="../Styles/page_styles.css" rel="stylesheet" type="text/css"/>
Needless to say the first chapter wasn't being correctly styled.

The "wrong" chapter also had an xml declaration :
Code:
<?xml version='1.0' encoding='utf-8'?>
<html xmlns="http://www.w3.org/1999/xhtml">
while all the others had :

Code:
<?xml version="1.0" encoding="UTF-8" standalone="no" ?><html xmlns="http://www.w3.org/1999/xhtml">
Although whether this is significant I don't know.

The original ODT is straightforward text separated by Chapter headers (formatted as "Heading 1") to ensure a proper TOC and the EPUB split by chapters.

Once I had spotted the errors it was easy to correct them with Sigil but is there anything I could be doing that would cause the errors in the first place ?

BobC

Last edited by BobC; 03-17-2013 at 03:42 PM.
BobC is offline   Reply With Quote