Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 03-20-2021, 05:49 AM   #1
what
Enthusiast
what began at the beginning.
 
Posts: 28
Karma: 10
Join Date: Mar 2021
Device: none
Cover and TOC as HTML or not?

When should I include the cover as an XHTML-page, and when shouldn't I? And when should I include the table of contents as an XHTML-page, and when shouldn't I? Are there ereaders or pulishers that require or cannot handle one or the other?
what is offline   Reply With Quote
Old 03-20-2021, 05:58 AM   #2
fbrzvnrnd
Fanatic
fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.
 
Posts: 554
Karma: 400004
Join Date: Feb 2009
Device: ONYX M96
Quote:
Originally Posted by what View Post
When should I include the cover as an XHTML-page, and when shouldn't I? And when should I include the table of contents as an XHTML-page, and when shouldn't I? Are there ereaders or pulishers that require or cannot handle one or the other?
ePub2 or EPUB3?
fbrzvnrnd is offline   Reply With Quote
Advert
Old 03-20-2021, 06:04 AM   #3
what
Enthusiast
what began at the beginning.
 
Posts: 28
Karma: 10
Join Date: Mar 2021
Device: none
I'm creating an epub3, but if that makes a difference, it should maybe be part of your answer.
what is offline   Reply With Quote
Old 03-20-2021, 07:22 AM   #4
fbrzvnrnd
Fanatic
fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.
 
Posts: 554
Karma: 400004
Join Date: Feb 2009
Device: ONYX M96
Quote:
Originally Posted by what View Post
I'm creating an epub3, but if that makes a difference, it should maybe be part of your answer.
The TOC in EPUB3 is a XHTML file, with a predefined structure. The cover, usually, is an image inside an XHTML file.
fbrzvnrnd is offline   Reply With Quote
Old 03-20-2021, 08:31 AM   #5
what
Enthusiast
what began at the beginning.
 
Posts: 28
Karma: 10
Join Date: Mar 2021
Device: none
I understand what they are. I just don't understand when I should have them and when I shouldn't. In Sigil, for example, it is an option. So there must be cases where it is better to have them, and cases where it is better not to have them.
what is offline   Reply With Quote
Advert
Old 03-20-2021, 09:42 AM   #6
phillipgessert
Addict
phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.phillipgessert ought to be getting tired of karma fortunes by now.
 
phillipgessert's Avatar
 
Posts: 311
Karma: 3196258
Join Date: Oct 2015
Location: Madison, WI
Device: Kindle 5th Gen
Quote:
Originally Posted by what View Post
I understand what they are. I just don't understand when I should have them and when I shouldn't. In Sigil, for example, it is an option. So there must be cases where it is better to have them, and cases where it is better not to have them.
I suppose I would say it is better to add a cover for books meant for personal use, since most purchased ones will inject one automatically, and it is better to add the html TOC for wider distribution, because not all devices support logical. Basically it is personal use, add or omit whatever you like; books for sale, add or omit according to required spec.
phillipgessert is offline   Reply With Quote
Old 03-20-2021, 11:30 AM   #7
fbrzvnrnd
Fanatic
fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.
 
Posts: 554
Karma: 400004
Join Date: Feb 2009
Device: ONYX M96
Quote:
Originally Posted by what View Post
I understand what they are. I just don't understand when I should have them and when I shouldn't. In Sigil, for example, it is an option. So there must be cases where it is better to have them, and cases where it is better not to have them.
I don't think you are forced to use a cover, but I don't think an EPUB could be validated without a TOC.
fbrzvnrnd is offline   Reply With Quote
Old 03-20-2021, 03:08 PM   #8
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,516
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Add an HTML cover when you want to be able to see it by paging back to page 1 (if you place it at the beginning). If I remember correctly, for ePub 2 there's no spec-sanctioned way to add a cover image, the '<meta name="cover"...>' tag is a de facto standard, but a renderer is not required to do anything special with that. Also some readers don't show covers anywhere, so if you want to make sure the cover is seen/displayed anywhere, add an HTML page with the image.

Similarly, add an HTML toc when you want to make sure it is displayed by paging back and forth, or when it requires special formatting. (Disclaimer: this is for ePub 2, the ePub 3 toc is an HTML page, as far as I know, but I'm not sure about the details of how/when/where it is shown.) If you have a fancy toc with images, summaries, complex structure, etc. you may need a full-blown HTML to show it, and the NCX is only a poor substitute (but required).

For example, I always include an HTML cover, and in the 1001 Nights I included not one, but two HTML tocs, to show the structure by nights and by stories.

Quote:
Originally Posted by fbrzvnrnd View Post
I don't think an EPUB could be validated without a TOC.
But (at least for ePub 2) that's an NCX toc, not an HTML one, which is what the question is about.
Jellby is offline   Reply With Quote
Old 03-20-2021, 04:01 PM   #9
fbrzvnrnd
Fanatic
fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.
 
Posts: 554
Karma: 400004
Join Date: Feb 2009
Device: ONYX M96
Quote:
Originally Posted by Jellby View Post
But (at least for ePub 2) that's an NCX toc, not an HTML one, which is what the question is about.
Uh? He said he was working on a EPUB3, not ePub2... or I'm missing something?
fbrzvnrnd is offline   Reply With Quote
Old 03-21-2021, 01:27 PM   #10
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 35,428
Karma: 145525534
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Forma, Clara HD, Lenovo M8 FHD, Paperwhite 4, Tolino epos
For epub3, you have no choice in including the ToC as an xhtml file since that is what the epub3 spec uses as the mandatory navigation document. You can hide the navigation document from displaying by controlling whether it is in the spine. I've done this on a couple of occasions when a overly fancy (IMHO) html ToC has been wanted.

For a cover page, I use one with an SVG wrapper and remove it for times when the book is being sent to Amazon.
DNSB is offline   Reply With Quote
Old 03-23-2021, 02:57 AM   #11
what
Enthusiast
what began at the beginning.
 
Posts: 28
Karma: 10
Join Date: Mar 2021
Device: none
Quote:
Originally Posted by DNSB View Post
For epub3, you have no choice in including the ToC as an xhtml file since that is what the epub3 spec uses as the mandatory navigation document. You can hide the navigation document from displaying by controlling whether it is in the spine. I've done this on a couple of occasions when a overly fancy (IMHO) html ToC has been wanted.

For a cover page, I use one with an SVG wrapper and remove it for times when the book is being sent to Amazon.
Thank you for the heads up about the epub3 spec.

As for the cover page, Amazon has accepted my epub with internal cover. Either they stripped it and replaced it with the separately submitted market cover image, or they left it intact. Either way, the version they sell now contains an internal cover. I didn't check the code to see if it remains unchanged.
what is offline   Reply With Quote
Old 03-23-2021, 09:26 AM   #12
jhowell
Grand Sorcerer
jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.
 
jhowell's Avatar
 
Posts: 6,497
Karma: 84420419
Join Date: Nov 2011
Location: Tampa Bay, Florida
Device: Kindles
Quote:
Originally Posted by what View Post
As for the cover page, Amazon has accepted my epub with internal cover. Either they stripped it and replaced it with the separately submitted market cover image, or they left it intact. Either way, the version they sell now contains an internal cover. I didn't check the code to see if it remains unchanged.
Amazon will usually strip out the original internal cover, but sometimes fails to detect it resulting in a book with a second cover page following the first one. It is a good idea to check your book to make sure that did not happen.
jhowell is online now   Reply With Quote
Old 03-23-2021, 09:31 AM   #13
what
Enthusiast
what began at the beginning.
 
Posts: 28
Karma: 10
Join Date: Mar 2021
Device: none
Quote:
Originally Posted by jhowell View Post
Amazon will usually strip out the original internal cover, but sometimes fails to detect it resulting in a book with a second cover page following the first one. It is a good idea to check your book to make sure that did not happen.
According to the downloadable preview file they provide as well as the preview on the product page, that did not happen.
what is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Some files.html & toc.xhtml (also Cover.xhtml) chaot Workshop 23 02-13-2017 12:20 PM
Multiple HTML files w/ TOC to MOBI, not added in order listed in TOC dysfunction Conversion 3 01-03-2014 12:40 AM
Cover Link in html TOC Sushil Kindle Formats 0 07-24-2012 04:30 AM
Kindler previewer not recognizing toc.ncx file, my html toc, or the start point... petercrowell Kindle Formats 2 05-01-2012 08:14 AM
HTML input plugin stripping text within toc tags in child html file nimblebooks Conversion 3 02-21-2012 03:24 PM


All times are GMT -4. The time now is 02:21 PM.


MobileRead.com is a privately owned, operated and funded community.