10-05-2021, 01:20 PM | #1 |
Guru
Posts: 748
Karma: 3000
Join Date: May 2009
Device: PRS-505, PRS-600, PRS-650
|
How to add ISBN to an EPUB file, to have it visible on my Elipsa?
Hello,
I’m working on a Bash script to create an EPUB with proper metadata, from a directory full of pictures, in other words, manga and comics, because official EPUBs are not always that great, some are even so badly formatted that spreads are not working correctly . Following advice from friends and looking at examples – either from the official EPUB websites, EPUB I purchased myself or using Sigil to have examples – , I’m including the ISBN and a unique ID randomly generated with uuidgen. As far as epubcheck is concerned, my Frankenstein code is valid – no error, no alert, nothing – and kepubify doesn’t report any error either, but my Kobo Elispa doesn’t show the ISBN while the rest of my EPUB metadata are shown – thanks to nickel series . I thought, after reading an old message from davidfor that I only needed to make sure that the ISBN was the first dc:identifier, but despite changing my script to do so, my Elipsa is still not showing the ISBN. The content.opf of my EPUB looks like that and the ISBN is the real ISBN from that book but no ISBN is shown by my Elipsa. Code:
<?xml version="1.0" encoding="utf-8"?> <package version="3.0" unique-identifier="pub-id" id="package" prefix="rendition: http://www.idpf.org/vocab/rendition/# cc: http://creativecommons.org/ns#" xml:lang="fr" xmlns="http://www.idpf.org/2007/opf"> <metadata xmlns:dc="http://purl.org/dc/elements/1.1/"> <dc:identifier id="isbn-id">urn:isbn:9782811622077</dc:identifier> <meta property="identifier-type" refines="#isbn-id" scheme="onix:codelist5">15</meta> <dc:identifier id="pub-id">urn:uuid:CC8757AF-657B-4CBB-BF2F-45252FAAABAB</dc:identifier> <meta property="identifier-type" refines="#pub-id" scheme="xsd:string">uuid</meta> Code:
<?xml version="1.0" encoding="utf-8"?> <ncx xmlns="http://www.daisy.org/z3986/2005/ncx/" version="2005-1"> <head> <meta name="dtb:uid" content="urn:uuid:CC8757AF-657B-4CBB-BF2F-45252FAAABAB"/> Content.opf Code:
<?xml version="1.0" encoding="utf-8"?> <package version="3.0" unique-identifier="isbn-id" id="package" prefix="rendition: http://www.idpf.org/vocab/rendition/# cc: http://creativecommons.org/ns#" xml:lang="fr" xmlns="http://www.idpf.org/2007/opf"> <metadata xmlns:dc="http://purl.org/dc/elements/1.1/"> <dc:identifier id="isbn-id">urn:isbn:9782811621957</dc:identifier> <meta property="identifier-type" refines="#isbn-id" scheme="onix:codelist5">15</meta> Code:
<?xml version="1.0" encoding="utf-8"?> <ncx xmlns="http://www.daisy.org/z3986/2005/ncx/" version="2005-1"> <head> <meta name="dtb:uid" content="urn:isbn:9782811621957"/> I'm sure it's a simple mistake on my part (I did plenty working on that script ), but if someone knows which one, I'm all hears |
10-05-2021, 08:24 PM | #2 |
Grand Sorcerer
Posts: 24,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
|
None of those look to be valid ways of defining the ISBN in the OPF. At least, they are not how calibre does them. Personally, I don't care about the ISBN on the device, as there is no use for it there, so I haven't checked it for a while (and honestly, other than an identifier to help get metadata, it's pretty useless). But, testing it now, what calibre puts in works.
For epub 2, this is: Code:
<dc:identifier id="isbn" opf:scheme="isbn">9781780891231</dc:identifier> For epub 3, it is: Code:
<dc:identifier>isbn:9780515135282</dc:identifier> And the above works fro sideloaded kepubs as well. |
Advert | |
|
10-05-2021, 09:01 PM | #3 |
Grand Sorcerer
Posts: 12,177
Karma: 73448616
Join Date: Nov 2007
Location: Toronto
Device: Nexus 7, Clara, Touch, Tolino EPOS
|
See if https://github.com/kobolabs/epub-spec helps; I do see some mention of metadata for the ISBN there.
Sent from my Pixel 4a using Tapatalk |
10-07-2021, 12:20 PM | #4 | |||
Guru
Posts: 748
Karma: 3000
Join Date: May 2009
Device: PRS-505, PRS-600, PRS-650
|
Thank you both for your answers
Quote:
I read them in examples from EPUB 3.2 specifications (like this one) and creating a fake book with Sigil also suggested the same way of definining it. I don’t think any of them would explain an invalid way of defining an ISBN inside an opf file. Quote:
Code:
<package version="3.0" id="package" unique-identifier="isbn" xml:lang="fr" xmlns="http://www.idpf.org/2007/opf"> <metadata xmlns:dc="http://purl.org/dc/elements/1.1/"> <dc:identifier id="isbn">isbn:9791039102759</dc:identifier> Quote:
Edit : I tested my first way of doing it one more time. With a side loaded .epub (something I didn't tried before), the urn:isbn:[isbn] is shown. With a kepubifyed epub, nope, nothing, what's an ISBN, etc I tried with the exact same epub, only changing the extension from epub to kepub.epub: my Elipsa is able to read the ISBN from the .epub file, but unable from the .kepub.epub (which unlike previous tests where I used Kepubify, here, my .kepub.epub is litteraly the exact same file, except for the extension) Last edited by Grimaud; 10-07-2021 at 02:02 PM. Reason: A couple of tests. |
|||
10-08-2021, 12:07 AM | #5 | ||||
Grand Sorcerer
Posts: 24,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
|
Quote:
Quote:
Quote:
Quote:
But, there is no real reason to expect the same results for both epubs and kepubs. They are different formats, follow different specs and are handled by completely different code. Epubs will be handled by the Adobe RMSDK, so you get whatever that supports. Kepubs are handled by something else, and as sideloaded kepubs are not officially supported, there is no way to actually know what should be done with them. |
||||
Advert | |
|
10-08-2021, 12:40 AM | #6 |
Guru
Posts: 873
Karma: 252902
Join Date: Jun 2016
Device: Kobo
|
@davidfor
kepub doesn't really show the ISBN in detail. I can't remember if it showed in the old firmware... and I'm just too lazy to roll back the firmware for verification. |
10-08-2021, 02:31 AM | #7 |
Grand Sorcerer
Posts: 24,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
|
It was something I explicitly tested yesterday. And I'm sure that it was read from the kepubs. But, trying again now, it didn't work. Now I'm not sure which device or books I tried yesterday
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
"Add from ISBN" adds empty entry for valid ISBN | halloleo | Library Management | 7 | 07-16-2021 10:47 PM |
Add ISBN to a PDF | Axell | Conversion | 0 | 06-20-2015 05:48 PM |
mobile add from isbn | goge | Development | 25 | 05-08-2015 08:16 AM |
How to add downloaded epub file to Kobo desktop library (not the reader)? | pdxesto | Kobo Reader | 8 | 06-17-2014 04:09 PM |
add css file to epub conversion | VICTORSJG | Calibre | 0 | 09-21-2011 07:38 AM |