|
|
View Full Version : book cover
nixwinter 04-13-2010, 03:43 PM hi!
I can get my book cover into the file.. and it shows in the interior, but it doesn't show on my ipad library... just a simple brown cover. This won't be so helpful.
I've put the cover image as the very first thing in the file.
What am I doing wrong?
Nix
Valloric 04-13-2010, 05:27 PM Since you have responded to the thread discussing iPad cover support (http://www.mobileread.com/forums/showthread.php?t=79037), you know that there needs to be a special <meta> tag in the metadata section of your OPF file.
The currently available version of Sigil doesn't not have this functionality since the iPad was just recently released. The next version of Sigil should have this.
For the time being, just create your epub file as normal, and then extract it with a zip tool, add the required <meta> element by hand and zip it back up (do note that the mimetype file has to be the first file in the final archive and also has to be uncompressed).
nixwinter 04-13-2010, 05:37 PM Since you have responded to the thread discussing iPad cover support (http://www.mobileread.com/forums/showthread.php?t=79037), you know that there needs to be a special <meta> tag in the metadata section of your OPF file.
The currently available version of Sigil doesn't not have this functionality since the iPad was just recently released. The next version of Sigil should have this.
For the time being, just create your epub file as normal, and then extract it with a zip tool, add the required <meta> element by hand and zip it back up (do note that the mimetype file has to be the first file in the final archive and also has to be uncompressed).
:) I have found the OPF file... the epub won't unzip with the build in zip program... it needed Stuffit... but what do I open an OPF file with?
I'm so sorry I'm so slow about all this :(
Nix
Valloric 04-13-2010, 05:43 PM In the thread I referenced there's a very good post by charleski (http://www.mobileread.com/forums/showpost.php?p=854445&postcount=5) illustrating what needs to be done.
nixwinter 04-13-2010, 06:04 PM In the thread I referenced there's a very good post by charleski (http://www.mobileread.com/forums/showpost.php?p=854445&postcount=5) illustrating what needs to be done.
It's so sad.. I've been working at this ALL day. I can get the file open, get the stuff I think ought to be there in, zip it all back up, but it doesn't work. I fear I have no idea what a dict anything is.
I swear I'm not stupid. I write really decent novels, do some decent art work.
I just don't understand why some new great universal format would want to be so insanely difficult. :( :( :( :( :( :(
paulpeer 04-14-2010, 12:48 AM No problem, Nixwinter. We'll do this step by step. 1) Go back to the ePub version before you started editing it (I hope you have made a backup). 2) Open the ZIP file and open the OPF file. 3) Since you have added the cover picture before, most of the meta data are already there. The only thing you should add is
<meta name="cover" content="cover-image" />
in the metadata section.
4) Now you have to change the word "cover-image" to the name Sigil gave to your cover image. This can be found in the manifest section of the same file. It is probably something like img0001.jpg (if you made your ePub with Sigil) and the name is preceded by id=
5) Save the file and zip all the files again as Valloric said before.
That's it. If it still doesn't work, post your entire OPF file so that we can have a look!
Valloric 04-14-2010, 06:14 AM If it still doesn't work, post your entire OPF file so that we can have a look!
Yeah, if you can't get it to work, just post your entire OPF here.
nixwinter 04-16-2010, 12:37 PM good morning!!!
I am so very grateful for you all's help!
I'm just a broke little writer/comic person. When I get this to work, and I can get this book sold through the ipad, and look decent while it's there, I shall offer you both a picture or story of your choice! :)
but... for today...
Here is where I'm trying to validate:
http://threepress.org/document/epub-validate/
I have a couple of files that will validate, but no covers. The cover is really important if I have any hope of paying my rent.
Just changing the extension from epub to zip and back to epub will cause the file to fail validation. (Makes me think the validation system is too crazy difficult, but that's another issue.)
Paulpeer: ) Go back to the ePub version before you started editing it (I hope you have made a backup). 2) Open the ZIP file and open the OPF file.
Me: *goes to do* Okay.. .the .opf file will open without changing the name, if I just point it towards Textwrangler... Also, I didn't change the name of the epub to zip... just pointed it towards stuffit expander
Paulpeer: 3) Since you have added the cover picture before, most of the meta data are already there. The only thing you should add is
Code:
<meta name="cover" content="cover-image" />
in the metadata section.
Me: *thinks... meta data section*.. *wonders if that's like the nose bleed section at the ballet* So there must be other meta data... I'll put it next to the other meta data *looks* Yup.. there was other meta data and I put it right below it... next step!
Paulpeer: 4) Now you have to change the word "cover-image" to the name Sigil gave to your cover image. This can be found in the manifest section of the same file. It is probably something like img0001.jpg (if you made your ePub with Sigil) and the name is preceded by id=
Me: This should not me as scary as it is... it's just some files. *slaps back of hand to palm* I can do this! Okay... Manifest section of the same file.... so.. in this same file I have open *looks* There it is! Labled with the <manifest> tag! *cheers*
okay.. so not this one: href="Images/shelly_Silveroak.jpg" but this one... id="shelly_Silveroak.jpg" and probably just shelly_Silveroak.jpg So I've made it:
<meta name="cover" content="shelly_Silveroak.jpg" />
:( I think I did it right. But it imports into itunes without a cover, and now it doesn't validate.
OPF file:
<?xml version="1.0" encoding="UTF-8"?>
<package xmlns="http://www.idpf.org/2007/opf" unique-identifier="BookID" version="2.0">
<metadata xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:opf="http://www.idpf.org/2007/opf">
<dc:title>The House of Silver Oak</dc:title>
<dc:creator opf:role="aut">Nix Winter</dc:creator>
<dc:language>en</dc:language>
<dc:identifier id="BookID" opf:scheme="CustomID">shelly_Silveroak.jpg</dc:identifier>
<meta name="Sigil version" content="0.2.0"/>
<meta name="cover" content="shelly_Silveroak.jpg" />
</metadata>
<manifest>
<item id="ncx" href="toc.ncx" media-type="application/x-dtbncx+xml"/>
<item id="shelly_Silveroak.jpg" href="Images/shelly_Silveroak.jpg" media-type="image/jpeg"/>
<item id="Section0001.xhtml" href="Text/Section0001.xhtml" media-type="application/xhtml+xml"/>
<item id="Section0002.xhtml" href="Text/Section0002.xhtml" media-type="application/xhtml+xml"/>
</manifest>
<spine toc="ncx">
<itemref idref="Section0001.xhtml"/>
<itemref idref="Section0002.xhtml"/>
</spine>
<guide>
<reference type="cover" title="Cover Page" href="Text/Section0001.xhtml"/>
</guide>
</package>
Validation Errors:
17nwinter_silver copy.epub Folder.epub is NOT valid
ERROR: 17nwinter_silver copy.epub Folder.epub: length of first filename in archive must be 8, but was 34
ERROR: 17nwinter_silver copy.epub Folder.epub: Required META-INF/container.xml resource is missing
Check finished with warnings or errors!
Preflight report
Epubpreflight runs some of the same validation as epubcheck, but additionally checks for problems like very large file sizes that might affect some reading systems.
ERROR: 17nwinter_silver copy.epub Folder.epub: mimetype entry missing or not the first in archive
ERROR: 17nwinter_silver copy.epub Folder.epub: META-INF/container.xml is missing
Check finished with warnings or errors!
charleski 04-16-2010, 01:15 PM just pointed it towards stuffit expander
Ah, you're using a Mac... your problem is that stuffit is messing up the archive.
The opf listing you posted looks fine, but you need to re-zip the files properly. Unpack all the files in the epub into a folder and make the changes you need in the opf file, then read this (http://www.mobileread.com/forums/showthread.php?t=55681) thread and use the little script that's attached there to repackage all the files as an epub.
nixwinter 04-16-2010, 01:46 PM That solution is fantastic! It will validate again! I owe you art or story!
But my cover is still not showing in itunes :(
If it ships to the ipad without a cover that will be sad. I can also give Sigil a credit on my isbn page if you'd like. As the software used to create the epub.
charleski 04-16-2010, 02:12 PM iTunes might not like the period in the cover id. Try
<?xml version="1.0" encoding="UTF-8"?>
<package xmlns="http://www.idpf.org/2007/opf" unique-identifier="BookID" version="2.0">
<metadata xmlns:dc="http://purl.org/dc/elements/1.1/" xmlnspf="http://www.idpf.org/2007/opf">
<dc:title>The House of Silver Oak</dc:title>
<dc:creator opf:role="aut">Nix Winter</dc:creator>
<dc:language>en</dc:language>
<dc:identifier id="BookID" opf:scheme="CustomID">shelly_Silveroak.jpg</dc:identifier>
<meta name="Sigil version" content="0.2.0"/>
<meta name="cover" content="cover_image" />
</metadata>
<manifest>
<item id="ncx" href="toc.ncx" media-type="application/x-dtbncx+xml"/>
<item id="cover_image" href="Images/shelly_Silveroak.jpg" media-type="image/jpeg"/>
<item id="Section0001.xhtml" href="Text/Section0001.xhtml" media-type="application/xhtml+xml"/>
<item id="Section0002.xhtml" href="Text/Section0002.xhtml" media-type="application/xhtml+xml"/>
</manifest>
<spine toc="ncx">
<itemref idref="Section0001.xhtml"/>
<itemref idref="Section0002.xhtml"/>
</spine>
<guide>
<reference type="cover" title="Cover Page" href="Text/Section0001.xhtml"/>
</guide>
</package>
I assume the opf file is in the root folder with two folders, 'Text' and 'Images', yes?
nixwinter 04-16-2010, 02:43 PM I'm not sure if it's in the root directory or not..
I've attached a screen shot. It's how the files came out of Sigil for me.
Nix
charleski 04-16-2010, 06:55 PM Looks like everything's in the right place.
paulpeer 04-17-2010, 03:00 AM iTunes might not like the period in the cover id.
No, that can't be the problem, Charleski. All my ebooks have this tag
<meta name="cover" content="img0001.jpg" />
and they appear perfectly in iTunes.
But what else can be wrong????
Daddy Warpig 04-22-2010, 10:04 PM Since you have responded to the thread discussing iPad cover support (http://www.mobileread.com/forums/showthread.php?t=79037), you know that there needs to be a special <meta> tag in the metadata section of your OPF file.
The currently available version of Sigil doesn't not have this functionality since the iPad was just recently released. The next version of Sigil should have this. One additional warning for Sigil 0.2.0 users:
Once you unzip the ePub and add the required meta information (and zip it back properly, change the extension, and add it back to iTunes) and it works:
Do NOT ever edit that ePub with Sigil again.
Sigil deletes the meta line from the .opf file (or maybe deletes and recreates the whole file, I'm not sure), and your cover will vanish (effectively, so far as iBooks is concerned).
Once again: after adding the required line by hand, do not edit the ePub with Sigil or it will disappear, and you'll have to add it back.
Fair warning.
paulpeer 04-23-2010, 01:00 AM One additional warning for Sigil 0.2.0 users:
Thanks for the warning, Daddy! I hadn't noticed this so far.
Daddy Warpig 04-23-2010, 01:31 AM I'm not sure if it's in the root directory or not..
I've attached a screen shot. It's how the files came out of Sigil for me.
Nix Shot in the dark: it could be that iTunes isn't syncing a new copy of the ePub, so you have the right info, it's just not on the iPad.
I've screwed around a bit and tried a lot of complicated things, most of which eventually worked, but I also found the easiest solution:
In iTunes, "Get Information" on the eBook and add or change something in the information. Add a grouping, add (or remove) a track number, change the title, paste in artwork, whatever.
As soon as something is changed in that screen, iTunes registers it as changed and it will sync properly the next time.
Good luck!
Daddy Warpig 04-25-2010, 01:16 AM Assuming your cover image is named "cover.jpg", the Sigil-generated .opf file always includes the following in the manifest (AFAICT):
<item id="cover.jpg" href="Images/cover.jpg" media-type="image/jpeg"/>
So, you don't have to worry about renaming anything in the manifest or scanning it to find the right id, just paste the following in the "Meta" head:
<meta name="cover" content="cover.jpg"/>
This line should always match the id in the manifest, and will tell iTunes to behave properly.
Save it, copy and paste it, and be sure to re-zip correctly.
Good Luck!
paulpeer 04-25-2010, 01:43 AM Assuming your cover image is named "cover.jpg", the Sigil-generated .opf file always includes the following in the manifest (AFAICT):
<item id="cover.jpg" href="Images/cover.jpg" media-type="image/jpeg"/>
No, that's not true. I suppose it depends on the way you create your ePub. In my case the id always is img0001.jpg.
So you have to check the manifest before adding the line.
Valloric 04-25-2010, 06:02 AM No, that's not true. I suppose it depends on the way you create your ePub. In my case the id always is img0001.jpg.
So you have to check the manifest before adding the line.
Actually what he said is true. The ID is created from the filename, and if your cover image filename is "cover.jpg", then Sigil will behave as Warpig said it will.
Either way, it will become a moot point after I add a WYSIWYG option for this later today. You'll be able to right-click an image in the Book Browser and select Add Semantics -> Mark As Cover Image. Sigil will take care of everything else.
paulpeer 04-25-2010, 06:24 AM Actually what he said is true. The ID is created from the filename, and if your cover image filename is "cover.jpg", then Sigil will behave as Warpig said it will.
Thanks for correcting me. This is the new way 0.2.0 does it, right? I'm still used to version 0.1, where the first imported image is renamed to img0001.jpg.
option for this later today.
That sounds good. Thank you, Valloric!
Valloric 04-25-2010, 06:52 AM Thanks for correcting me. This is the new way 0.2.0 does it, right? I'm still used to version 0.1, where the first imported image is renamed to img0001.jpg.
You're right, your previous statement is correct if you're using 0.1.9. I haven't looked at 0.1.x code in many months now...
Valloric 04-26-2010, 02:24 PM Either way, it will become a moot point after I add a WYSIWYG option for this later today. You'll be able to right-click an image in the Book Browser and select Add Semantics -> Mark As Cover Image. Sigil will take care of everything else.
This is now implemented. See the related dev blog post (http://sigildev.blogspot.com/2010/04/new-add-semantics-menu.html).
Daddy Warpig 04-26-2010, 07:46 PM This is now implemented. See the related dev blog post (http://sigildev.blogspot.com/2010/04/new-add-semantics-menu.html). According to the post, it's going to be released as part of RC1. Any ETA on that?
paulpeer 04-27-2010, 04:05 AM This is now implemented. See the related dev blog post (http://sigildev.blogspot.com/2010/04/new-add-semantics-menu.html).
O boy, I've been testing Sigil for many months now, and I wasn't aware of the existence of this blog. It has lots lots of useful information about the functioning of Sigil. Thanks for that, Valloric, but you should more often tell the forum members about your blog. Or was I the only blind one not aware of its existence? :smack:
Valloric 04-27-2010, 06:21 AM According to the post, it's going to be released as part of RC1. Any ETA on that?
Hopefully in the next 10 days. If I miss this window, then two weeks after that since I'll have some other duties coming up soon.
O boy, I've been testing Sigil for many months now, and I wasn't aware of the existence of this blog. It has lots lots of useful information about the functioning of Sigil. Thanks for that, Valloric, but you should more often tell the forum members about your blog. Or was I the only blind one not aware of its existence? :smack:
There a sticky thread (http://www.mobileread.com/forums/showthread.php?t=65396) in this subforum titled "New Sigil development blog", and the blog is also linked from the project main page... twice.
I don't know how to make it more prominent than that. :)
mbbraverman 05-13-2010, 02:26 PM Hi - I'm new here and feel fortunate to have found you. My problem is similar: I'm publishing an ePub to Lightning Source and my book (384 pages; some of it not too bad). I used Sigil exclusively and the ePub output passed the Threepress ePub validity check - that is, until I insert a cover and small photo on the last page. The Threepress error message is "missing attribute". What attribute is it looking for? Thanks for any help you can provide.
Valloric 05-13-2010, 02:53 PM Hi - I'm new here and feel fortunate to have found you. My problem is similar: I'm publishing an ePub to Lightning Source and my book (384 pages; some of it not too bad). I used Sigil exclusively and the ePub output passed the Threepress ePub validity check - that is, until I insert a cover and small photo on the last page. The Threepress error message is "missing attribute". What attribute is it looking for? Thanks for any help you can provide.
It's impossible to help without seeing the epub file.
mbbraverman 05-13-2010, 02:59 PM It's impossible to help without seeing the epub file.
Thanks, Valloric - how do I upload the ePub file to you?
Valloric 05-13-2010, 03:01 PM Thanks, Valloric - how do I upload the ePub file to you?
See this page (http://code.google.com/p/sigil/wiki/ReportingIssues).
paulpeer 05-13-2010, 11:29 PM Hi - I'm new here and feel fortunate to have found you. My problem is similar: I'm publishing an ePub to Lightning Source and my book (384 pages; some of it not too bad). I used Sigil exclusively and the ePub output passed the Threepress ePub validity check - that is, until I insert a cover and small photo on the last page. The Threepress error message is "missing attribute". What attribute is it looking for? Thanks for any help you can provide.
You just have to add alt="description of the image" after "<img". This is required by XHTML but Sigil doesn't support it yet.
Valloric 05-14-2010, 03:54 AM You just have to add alt="description of the image" after "<img". This is required by XHTML but Sigil doesn't support it yet.
"Doesn't support it"? Are you saying that Sigil will remove the ALT attribute for your images?
mbbraverman 05-14-2010, 10:51 AM Thanks for the heads up. I'll try it and see what happens. Also, when I apply the "cover" semantic in the Images folder, my cover is expressed in the left hand pane as "Content001.xhtml" instead of "coverxxxx"
flipsake 06-29-2010, 04:33 AM don't know if this has been said, but I've notice that itunes doen't seem to like spaces in the image file names for the cover art. Changing the name of the image to something without spaces seems to work.
I've done this for my books in Sigil and had no problems since.
mbbraverman 06-29-2010, 10:48 AM Thank you. Much appreciated.
|