In Children’s Fixed Layout ePub for iPad – Part 10, the toc.ncx (navigation) file was explained for your fixed layout ePub.

The content.opf file describes how the files containing the children’s eBook content are connected in a fixed layout ePub.

There are four parts in the content.opf file:

  • The Metadata

This section includes the information such as the title, who wrote the book, ISBN number, language, publisher and the date of publication or date you finished the fixed layout ePub.

  • The Manifest

Lists every file in your fixed layout ePub along with the file type of each. It’s extremely important all files included in the .epub file be in the manifest section or your eBook will fail (meaning have errors) when epubcheck is applied.

Plus Apple will not accept a Children’s fixed layout ePub into their iBookstore if it’s failed epubcheck.

  • The Spine

The spine section is the linear reading order of the ebook’s .xhtml files. In other words, this tells iBooks application what the next page is in your eBook.

  • The Guide

The elements in the guide list the key parts of your eBook which will be your cover image and what .xhtml page you want your eBook to start on. A Children’s fixed layout ePub does not have a Table of Contents. It just has small thumbnails at the bottom of iBooks and they only show up when starting the eBook or when the screen is tapped.

Now let’s discuss the content.opf code in a fixed layout ePub.

Again what is bold and in blue is what you’ll change for your eBook. Capital letters were used just to make it EZ-ier for you to see what should be changed.

Below is just saying the type of file in “geek” language:

<package xmlns=”http://www.idpf.org/2007/opf” unique-identifier=”book-id” version=”2.0″>

Next is the Medadata information:

<metadata xmlns:dc=”http://purl.org/dc/elements/1.1/” xmlns:opf=”http://www.idpf.org/2007/opf”>
<dc:title id=”en_title” xml:lang=”en-us”>YOUR TITLE HERE</dc:title>
<dc:creator id=”creator_aut” opf:file-as=”LASTNAME, FIRSTNAME” opf:role=”aut”>FIRSTNAME LASTNAME</dc:creator>
<dc:subject>Children’s Fiction</dc:subject>
<dc:identifier id=”book-id”>YOUR ISBN GOES HERE</dc:identifier>
<dc:description id=”en_description” xml:lang=”en-us”>DESCRIPTION HERE</dc:description>
<dc:publisher id=”en_publisher” xml:lang=”en-us”>PUBLISHER NAME</dc:publisher>
<dc:date id=”date_1″ opf:event=”publication”>YYYY-MM-DD</dc:date>
<dc:rights id=”en_rights” xml:lang=”en-us”>copyright YOUR NAME</dc:rights>
<dc:language id=”en_language”>en-us</dc:language>
<meta name=”cover” content=”coverimage” />
</metadata>

Make sure your description is enticing because after the cover, it’s the next thing your customer looks at to see if they want to either sample your eBook or buy it.

If you’re making a fixed layout ePub for someone other than yourself then their name would go between the Author tags.

The Manifest code section lists all the files in your eBook. The list for both your .css,.xhtml, image, audio and .smil files will, of course, be longer. This is just a generic content.opf file.

You’ll notice in the .xhtml section that it shows media-overlay which is used for pages with audio. This media overlay code spits out an error message when you use epubcheck. Ignore this error message as this particular code is used by Apple so iBooks knows it’s a read aloud eBook.

<manifest>
<item id=”toc” href=”toc.ncx” media-type=”application/x-dtbncx+xml” />
<item id=”playlist” href=”iTunesMetadata.plist” media-type=”text/plist” />

<!– css –>
<item id=”css1″ href=”css/styles.css” media-type=”text/css” />
<item id=”css2″ href=”css/copyright01.css” media-type=”text/css” />
<item id=”css3″ href=”css/page01.css” media-type=”text/css” />

<!– xhtml –>
<item id=”item01″ media-type=”application/xhtml+xml” href=”cover.xhtml” />
<item id=”item02″ media-type=”application/xhtml+xml” href=”copyright01.xhtml” />
<item id=”item03″ media-type=”application/xhtml+xml” href=”copyright02.xhtml” media-overlay=”copyright02smil” / >
<item id=”item04″ media-type=”application/xhtml+xml” href=”page01.xhtml” media-overlay=”page01smil” />
<item id=”item05″ media-type=”application/xhtml+xml” href=”page02.xhtml” media-overlay=”page02smil” />

<!– images –>
<item id=”coverimage” href=”images/cover.jpg” media-type=”image/jpeg” />
<item id=”copyright01.xhtml” href=”images/copyrightleft.jpg” media-type=”image/jpeg” />
<item id=”copyright02.xhtml” href=”images/copyright02.jpg” media-type=”image/jpeg” />
<item id=”page01.xhtml” href=”images/1-wunkhomenomoonleft.jpg” media-type=”image/jpeg” />
<item id=”page02.xhtml” href=”images/2-wunkhomeright.jpg” media-type=”image/jpeg” />

<!–audio–>
<item id=”copyright02audio” href=”audio/copyright02.m4a” media-type=”audio/mpeg” />
<item id=”page01audio” href=”audio/page01.m4a” media-type=”audio/mpeg” />
<item id=”page02audio” href=”audio/page02.m4a” media-type=”audio/mpeg” />

<!–smil–>
<item id=”copyright02smil” href=”copyright02.smil” media-type=”application/smil+xml” />
<item id=”page01smil” href=”page01.smil” media-type=”application/smil+xml” />
<item id=”page02smil” href=”page02.smil” media-type=”application/smil+xml” />
</manifest>

Next up in the content.opf file is the Spine section of the fixed layout ePub and references (idref) what you put in the Manifest section under .xhtml part. Remember, this is the linear order or in layman terms, the way you want your reader to proceed through your Children’s fixed layout ePub:

<spine toc=”toc”>
<itemref idref=”item01” />
<itemref idref=”item02” />
<itemref idref=”item03” />
<itemref idref=”item04” />
<itemref idref=”item05” />
</spine>

For a Children’s fixed layout ePub, the guide section only needs your cover information and where you want your eBook to start. In my eBook, my copyright page had the picture of my cover but the words were all positioned on it so they could be read aloud. You might want to do this differently so you would put the .xhtml page of what you want your reader to see first:

lt;guide>
<reference type=”cover” title=”Cover Image” href=”cover.xhtml” />
<reference type=”text” title=”YOUR TITLE HERE” href=”copyright01.xhtml” />
</guide>

And finally, since you started the content.opf for your fixed layout ePub with the package information, you need to put in the ending tag for it:

</package>

Tip: An EZ way to keep track of all the items that go into your the content.opf file is to put your .xhtml, images, audio, .smil files into the sections as you finish them.

A completed content.opf file in your fixed layout ePub would look like this in your text editor:

example of content opf file in a fixed layout ePub

And this completes our posts on how to make a Children’s Fixed Layout ePub.