View Single Post
Old 01-19-2019, 06:49 PM   #4
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 2,306
Karma: 13057279
Join Date: Jul 2012
Device: Kobo Forma, Nook
I'll try to color-code my stuff, maybe that'll make it easier to understand too!

Let's say you rip open a book created in Sigil.

In your content.opf, you'll see something like this:

Spoiler:
Quote:
<?xml version="1.0" encoding="utf-8"?>
<package version="2.0" unique-identifier="BookId" xmlns="http://www.idpf.org/2007/opf">
<metadata xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:opf="http://www.idpf.org/2007/opf">

<dc:language>en</dc:language>
<dc:title>[Title here]</dc:title>
<dc:identifier opf:scheme="ISBN">1-23456-789-0</dc:identifier>
<dc:identifier opf:scheme="UUID" id="BookId">urn:uuid:73be470e-4da2-4f78-83bf-7ac69507aa66</dc:identifier>

</metadata>
[...]


These two always have to match:

- unique-identifier (up top)
- id (down below)

You can see they both say BookId.

Note: Sigil uses "BookId", but you could call this anything.

Note #2: The blue part is just a randomly generated UUID. All books are probably going to have different gibberish here depending on which program built it.

Method 1

As Diap initially explained, you can change "BookId" to whatever name you name want. He mentioned he likes to use "isbn".

So change both red parts, and move the id to where it's needed:

Spoiler:
Quote:
<?xml version="1.0" encoding="utf-8"?>
<package version="2.0" unique-identifier="isbn" xmlns="http://www.idpf.org/2007/opf">
<metadata xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:opf="http://www.idpf.org/2007/opf">

<dc:language>en</dc:language>
<dc:title>[Title here]</dc:title>
<dc:identifier opf:scheme="ISBN" id="isbn">1-23456-789-0</dc:identifier>
<dc:identifier opf:scheme="UUID" id="BookId">urn:uuid:73be470e-4da2-4f78-83bf-7ac69507aa66</dc:identifier>

</metadata>
[...]


Remove the entire Blue line because it's not needed any more:

Spoiler:
Quote:
<?xml version="1.0" encoding="utf-8"?>
<package version="2.0" unique-identifier="isbn" xmlns="http://www.idpf.org/2007/opf">
<metadata xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:opf="http://www.idpf.org/2007/opf">

<dc:language>en</dc:language>
<dc:title>[Title here]</dc:title>
<dc:identifier opf:scheme="ISBN" id="isbn">1-23456-789-0</dc:identifier>

</metadata>
[...]


Method 2

Or as Turtle91 said:

Just move the id="BookId":

Spoiler:
Quote:
<?xml version="1.0" encoding="utf-8"?>
<package version="2.0" unique-identifier="BookId" xmlns="http://www.idpf.org/2007/opf">
<metadata xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:opf="http://www.idpf.org/2007/opf">

<dc:language>en</dc:language>
<dc:title>[Title here]</dc:title>
<dc:identifier opf:scheme="ISBN" id="BookId">1-23456-789-0</dc:identifier>
<dc:identifier opf:scheme="UUID">urn:uuid:73be470e-4da2-4f78-83bf-7ac69507aa66</dc:identifier>

</metadata>
[...]


And you can delete the entire blue line:

Spoiler:
Quote:
<?xml version="1.0" encoding="utf-8"?>
<package version="2.0" unique-identifier="BookId" xmlns="http://www.idpf.org/2007/opf">
<metadata xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:opf="http://www.idpf.org/2007/opf">

<dc:language>en</dc:language>
<dc:title>[Title here]</dc:title>
<dc:identifier opf:scheme="ISBN" id="BookId">1-23456-789-0</dc:identifier>

</metadata>
[...]


Quote:
Originally Posted by Trane View Post
EDIT: Argh, even my posts are making fun of me, inserting smileys!
Use [noparse][/noparse] tags around those stupid smilies. :P

Or when you're in the Advanced Editor, right below "Submit Reply" button, you can see a little checkbox for Disable smilies in text.
Tex2002ans is offline   Reply With Quote