Tools, FAQ, Tutorials:
3Pigs4-3.1.epub - Cover Image and Page
How to add a cover image to my EPUB books
✍: FYIcenter.com
If you want to add a cover image to your EPUB 3.1 book,
you should consider to two related components:
You can follow this tutorial to add a cover image and a cover page to your EPUB 3.1 book.
1. Get your cover image file ready with an aspect radio of 6"x9" (or 720x1080 pixel, assuming 120 DPI). The cover image can be stored in *.jpg format, for example: The-Wolf-Blows-Down-the-Straw-House.jpg.
The image size should not be too big, better to be < 720x1080 pixels. Otherwise, EPUB readers may have issues displaying them.
2. Add a cover image to your book by adding a "manifest" "item" in package.opf, with properties="cover-image":
<item id="Cover" href="/The-Wolf-Blows-Down-the-Straw-House.jpg" media-type="image/jpeg" properties="cover-image"/>
3. Add a cover page to your book by adding an XHTML file like Cover-Page.xhtml, which should have just 1 simple "img" element:
<?xml version="1.0" encoding="utf-8"?> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>The Cover Page</title> </head> <body> <div><img src="/The-Wolf-Blows-Down-the-Straw-House.jpg" alt="The Wolf Blows Down The Straw House"/> </div> </body> </html>
4. Remember to include cover page in package.opf:
... <manifest> <item id="Cover" href="/The-Wolf-Blows-Down-the-Straw-House.jpg" media-type="image/jpeg" properties="cover-image"/> <item id="Navigation" href="/navigation.xhtml" media-type="application/xhtml+xml" properties="nav"/> <item id="Cover-Page" href="/Cover-Page.xhtml" media-type="application/xhtml+xml"/> ... </manifest> <spine> <itemref idref="Navigation" linear="no"/> <itemref idref="Cover-Page"/> ... </spine> ...
For example, you can download this EPUB book, 3Pigs4-3.1.epub, which contains a cover image and a cover page.
If you open 3Pigs4-3.1.epub in Calibre and go
to beginning of the book, you see the cover page displayed:
⇒ 3Pigs5-3.1.epub - Title Page and TOC
⇐ 3Pigs3-3.1.epub - Add Images
2018-12-26, 1870🔥, 0💬
Popular Posts:
How To Pad an Array with the Same Value Multiple Times in PHP? If you want to add the same value mul...
Where to get a JSON.stringify() Example Code in JavaScript? Here is a good JSON.stringify() example ...
Can Two Forms Be Nested? Can two forms be nested? The answer is no and yes: No. You can not nest two...
How to use "{{...}}" Liquid Codes in "set-body" Policy Statement? The "{{...}}" Liquid Codes in "set...
How to troubleshoot the Orderer peer? The Docker container terminated by itself. You can follow this...