03-17-2013, 03:32 PM | #1 |
Guru
Posts: 691
Karma: 3026110
Join Date: Dec 2008
Location: Lancashire, U.K.
Device: BeBook 1, BeBook Pure, Kobo Glo, (and HD),Energy Sistem EReader Pro +
|
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"/> Code:
<link href="../Styles/stylesheet.css" rel="stylesheet" type="text/css"/> <link href="../Styles/page_styles.css" rel="stylesheet" type="text/css"/> The "wrong" chapter also had an xml declaration : Code:
<?xml version='1.0' encoding='utf-8'?> <html xmlns="http://www.w3.org/1999/xhtml"> Code:
<?xml version="1.0" encoding="UTF-8" standalone="no" ?><html xmlns="http://www.w3.org/1999/xhtml"> 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. |
03-18-2013, 01:25 AM | #2 |
creator of calibre
Posts: 43,839
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
|
Advert | |
|
03-18-2013, 06:56 AM | #3 |
Guru
Posts: 691
Karma: 3026110
Join Date: Dec 2008
Location: Lancashire, U.K.
Device: BeBook 1, BeBook Pure, Kobo Glo, (and HD),Energy Sistem EReader Pro +
|
I have re-done the conversion from scratch so all files are clean.
I have had to ZIP up the ODT to upload it. The problem is as described in the original post and the affected file within the EPUB is index_split_033.xhtml. I am viewing the EPUB with SIGIL, however I have now exploded the book with Calibre and examined the offending files with Notepad and it appears that on opening SIGIL is changing all files except ..._033. In the directly converted EPUB the stylesheets are in the same folder as the text files, SIGIL must be changing the structure on loading to put the css files in a Styles folder (and creating other folders) and not doing a complete job. If this is the case then the problem is not with the Calibre conversion but it appears unwise to use the "Open with Sigil" option in Calibre to make changes to the EPUB without being aware of possible side-effects such as this. BobC For completeness - I have just downloaded SIGIL 0.71 and that does not create the problem I had previously so my comment on not using SIGIL is only applicable if using 0.70 Last edited by BobC; 03-18-2013 at 07:43 AM. Reason: Added reference to SIGIL 0.71 |
Thread Tools | Search this Thread |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Glo Lagging/odd behaviour | rainio | Kobo Reader | 5 | 11-17-2012 10:45 AM |
Odd-behaviour on PDFs on 912 | jedd | PocketBook | 0 | 05-10-2012 11:45 AM |
Odd behaviour | Kboland | Kobo Tablets | 5 | 01-01-2012 11:03 PM |
Odd behaviour of Calibre in Windows 7 | bmeddings | Calibre | 10 | 04-16-2010 09:59 AM |
Odd Behaviour... | swanson37 | Sony Reader | 4 | 11-14-2007 01:11 AM |