12-01-2016, 05:24 AM | #1 |
Age improves with wine.
Posts: 571
Karma: 95229
Join Date: Nov 2014
Device: Kindle Oasis, Kobo Libra II
|
ToC help needed: nav.xhtml
I am trying to add a ToC to a book, but when I do I get two files: toc.ncx and nav.xhtml, both of which are marked with a ToC icon, and a warning that nav.xhtml isn't referenced. Annoyingly, nav.xhtml shows up as the last page of the book when I look at it in a reader.
The OPF file contains this: Code:
... <item href="toc.ncx" id="toc" media-type="application/x-dtbncx+xml"/> <item href="nav.xhtml" id="nav" media-type="application/xhtml+xml" properties="nav"/> </manifest> <spine toc="toc"> ... Can anyone tell me what is going on here, why the nav.xhtml is created, and how I can get rid of it? |
12-01-2016, 05:25 AM | #2 |
creator of calibre
Posts: 44,708
Karma: 24967300
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
nav.xhtml is needed for EPUB 3 books. You dont want it change your book back to EPUB 2.
|
Advert | |
|
12-01-2016, 05:33 AM | #3 |
Age improves with wine.
Posts: 571
Karma: 95229
Join Date: Nov 2014
Device: Kindle Oasis, Kobo Libra II
|
|
12-01-2016, 05:37 AM | #4 |
creator of calibre
Posts: 44,708
Karma: 24967300
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
I am certainly no fan of EPUB 3.
|
12-01-2016, 07:38 AM | #5 |
Resident Curmudgeon
Posts: 77,186
Karma: 138591138
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
ePub 3 is a mistake. What ePub 3 should have been is ePub 2+ meaning don;t change things that don't need to be changed and make the changes logical. Also, do away with audio and video. They don't need to exist in eBooks.
|
Advert | |
|
12-02-2016, 10:54 PM | #6 | |
Wizard
Posts: 1,117
Karma: 1261763
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
|
Quote:
Lol.... The nav.xhtml is a required file for epub3 books, as Kovid Goyal explained. But it was not necessary to change the version on the package, as now your book probably won't pass epubcheck. If you don't want the nav.xhtml appearing in the book, just leave it out of the spine. Forget about the warning saying it is not referenced. It just calls your attention to the fact that there is an xhtml file being left out of the spine. |
|
12-10-2016, 07:10 AM | #7 | |
Age improves with wine.
Posts: 571
Karma: 95229
Join Date: Nov 2014
Device: Kindle Oasis, Kobo Libra II
|
Quote:
|
|
12-10-2016, 07:50 AM | #8 |
Resident Curmudgeon
Posts: 77,186
Karma: 138591138
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
If you are creating an ePub 2 eBook, you do not need a nav file. You don't even need an HTML ToC. All you need is the NCX.
|
04-09-2017, 01:00 PM | #9 | |
Wizard
Posts: 1,117
Karma: 1261763
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
|
Quote:
The toc.xhtml shows up even if it is not on the spine? I'm not talking about marking it as "non-linear". I've never seen that happen. What reader do you use? As for being a valid EPUB2, I was led to believe that you had a EPUB3 file and just changed the version from "3.0" to "2.0". If you just did that, the epub wouldn't be a valid EPUB2, since there are other diferences between the formats. Last edited by thiago.eec; 04-09-2017 at 01:13 PM. |
|
04-09-2017, 06:18 PM | #10 | |
Resident Curmudgeon
Posts: 77,186
Karma: 138591138
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
|
|
04-14-2017, 05:58 AM | #11 |
Wizard
Posts: 1,117
Karma: 1261763
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
|
Well, what you are suggesting is to change it back to the epub2 format. Then, why not just create an epub2, from the beginning?
|
Tags |
toc error |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
EPUBTEST 0150 - EPUB Navigation Document Tests: toc nav not supported | quiris | Marvin | 3 | 07-06-2016 03:11 PM |
Ibooks epub 3 error : exactly one 'toc' nav element must be present | Firebrand007 | ePub | 6 | 01-02-2015 11:00 PM |
TOC xhtml | giosa | Sigil | 3 | 01-17-2012 10:12 PM |
Bug Report: Mobi Conversion puts TOC Nav in wrong spot | therealjoeblow | Conversion | 4 | 12-02-2011 10:56 AM |