WebVivant

First few days with the third-generation Kindle

Okay, so I caved. I still think the Kindle is a dead-end technology. But I bought one anyway.

KindleThe reason I gave in and bought a third-generation Kindle was simple: price. With the wifi + 3G version now only $189, it finally falls into that price bracket of 'worth a try'. If I decide in the end that it's not working out, I won't have blown too much money — assuming that I haven't invested a great deal in books (but more of that later).

The improvements with the third-generation Kindle (or Kindle 3 as it's inevitably, but unofficially being called) don't end with the price drop. Amazon has reduced the size and weight and adopted the latest screen technology — the Pearl e-ink display.

And then there's the small matter of not having any other e-reader. At WebVivant Press we're publishing e-books, but my only experience so far of reading them has been on the laptop. That's just not right. I wanted to find out what the e-reader experience is like.

I could have bought a Nook, or a Sony e-reader. But, frankly, of the dedicated e-readers on the market, the Kindle strikes me as the only long-term prospect. Besides which, we publish on the Kindle through Amazon DTP, so it seemed like the right move.

The other option was the Apple iPad, but there were two very good reasons for not going that route: 1) it starts at 499 euros; and 2) it's still version 1 and I never buy v.1 of anything, especially when it's from Apple (and I'm a fan of their products).

First impressions

I opened the box (entirely made of recyclable card, BTW), lifted out the Kindle, peeled off a couple of transparent plastic protective sheets and was about to peel off a sticker covering the whole screen when I realised there was no sticker. What appeared to be a printed sheet was, in fact, the display itself. That's a good first impression.

E-ink displays are the opposite of laptop screens — the brighter the ambient light the easier they are to read. Sitting in the garden on a dazzling sunny August day, the Kindle's screen was a joy to use — very easy on the eyes. As light levels drop, that's when you start squinting. Now, you could say the same is true for those archaic, last-century reading devices … what are they called? … oh yes, books. And that's true except that, even with the latest Pearl screen, the Kindle still doesn't achieve the contrast (and therefore readability) of the printed page. It's not far off, mind, but there's enough of a difference that, as the sunlight fades, you'll be hunting for the light switch sooner with a Kindle than you would with a book.

The Kindle comes with a pre-loaded manual, but I've been a tech journalist for nearly 30 years and I'm damned if I'm going to start reading manuals now. Fortunately, navigation is reasonably intuitive. I showed the Kindle to a bunch of friends at a writer's group meeting. None of the group members is what you'd call in the first flush of youth, and among the people I know these are the least likely to be impressed by a gimmick or 'cool' bit of technology. But all were, in fact, impressed. One person (who, admittedly, is at least reasonably tech-savvy and certainly far above average intelligence) was quickly moving between books, checking out the text-to-speech feature and generally finding her way around with no prompting from me.

Connectivity

Where the Kindle scores above many other e-readers is the tight integration with Amazon. That sounds obvious, but an important part of the Kindle experience is not having to switch to a computer to find and download books. Immediate access to the Amazon store from the Kindle itself makes it a competely stand-alone product.

For example, during lunch, the subject of conversation alighted on Jack London and I had to admit I'd never read White Fang. A few moments later I had a free copy of the book on the Kindle (even with a slow Edge connection — no 3G around here). One of our group, a 70 year-old with, as far as I know, no special love of technological toys, was soon buried in the book, having adjusted the font size to compensate for not having his reading glasses with him. He said he found he was changing pages without any conscious action, just as one might flip the pages of a printed book.

Indeed, what I've found with the Kindle is that one can easily ignore it. When I read an e-book on the screen of my laptop, I'm always aware of the machine somehow. I have to try to see through it. It's an effort. With the Kindle, just as with a book, I soon lose any awareness of the physical object and am quickly inside the world of the story. I think the e-ink technology has a lot to do with this — its easiness on the eye erases the barrier between you and the text.

The Kindle also copes well with my pathological compulsion to make notes. Highlighting sections of text is easy, and you can add your own notes. Or you can simply mark a page with a bookmark. You don’t need to do this to remember where you are — the Kindle automatically keeps your place, even as you flip back and forth between books. And there’s an option to synchronise your place between the Kindle and the Kindle apps on your computer, smartphone or iPad.

When reading magazines or newspapers, there's an option to 'clip' the article you're reading. This adds the text of the article to a file (just one file for all your clippings) which you can download on to a computer. No doubt this will prove a huge boon for students who need to plagiarise when writing papers.
The search facilities are not bad, too. The search results pages show chunks of text with your keywords highlighted, so it's easy to see the context and know which results are relevant.

Other features

The Amazon store access is provided by dedicated software. But you can also browse the web on this machine. The web browser is surprisingly good, though slow. It wouldn't be my first choice of platform for mobile web use, but it'll do in a pinch.

Amazon still classifies the browser as one of the Kindle's 'experimental' features. Another is the text-to-speech feature, which is mostly ghastly. The voice pauses in all the wrong places. It's like being read to by Stephen Hawkins' idiot brother. I can't think of a single use for it. If you're sight-impaired, go for real audiobooks instead. It's bad enough being blind without having to put up with this.

As someone who doesn't text (in fact, I don't even have a mobile phone anymore), using the keyboard with its tiny buttons is a challenge. Given that you can increase the size of the display font, I was going to recommend the Kindle to a friend with eyesight issues. But this barely visible keyboard ruled that out.

I've invested quite a lot of time working out how to hold the damn thing. The new Kindle is lighter and smaller than its predecessors. In fact, as far as weight goes, it's not dissimilar to a lot of paperback books. It's just that I've found it tricky to hold comfortably without hitting the back/forth paging buttons or the keyboard. I'm starting to think that a leather case would actually make it easier and more comfortable to hold.

Mixed blessings

So far, finding books for the Kindle has been slightly frustrating. Bestselling novels are generally not hard to find. But my tastes tend to run a little more eclectic, and so far I've found that only about one in three is available in Kindle format.

And in spite of Amazon's much publicised battles with publishers to get them to bring down prices, some Kindle editions can run rather more expensive than I'd like.

Against that is the availability of so many classic texts as free editions. These editions have largely been created by enthusiasts and volunteers (like Project Gutenberg) so the quality is variable. You get rogue carriage returns. There are rarely clickable tables of contents. But it's surprising how little any of that matters when the price is so right. Within minutes of starting to use the Kindle I had works by Austen, Dickens, Kipling, Swift, Chekhov, Wharton and Dostoyevsky, plus On the Origin of Species.

And in spite of my complaint above, there are inexpensive editions. I spent something like $3.75 for a good version of the King James Version of the Bible, with clickable contents and navigation links. (As an atheist, I've filed this under 'classic fiction'.)

A few reservations

The Kindle is not perfect. In fact, I still have a few reservations about the entire concept. I'm very conscious of the fact that any books I buy will be available to me only so long as I have a Kindle reading device. Now, that could include, say, an iPad with the Kindle app. Indeed, around 20% of the people buying and reading Kindle editions are doing so on something other than a Kindle. But all the same, the relative lock-in to the Kindle ecosystem does give me pause. I will probably limit my Kindle purchases to free books, and those I am likely to read only once or twice.

It also annoys the crap out of me that I can't load our ePub e-books on to this machine. (I tried, just in case Amazon had made the Kindle ePub compatible without telling anyone. They hadn't.)

You can get books on to the Kindle other than by buying them from the store. You can plug the Kindle into your computer, which will view it as an external disk drive. You then just copy readable files (plain text and PDF, for example) to the device.

Amazon also gives you a special email account: <YourUserName>@kindle.com. You can email various types of file (eg, Word documents) to this email address at which point Amazon converts the file to Kindle format and downloads it to your device. There's a small charge for this — $0.15/MB — presumably to cover the wireless costs. Alternatively, you can email the file to <YourUserName>@free.kindle.com. Amazon then converts the file and makes it available for you to download, via the web browser on your computer. You can then copy it across to the Kindle.

The future

In spite of the browser and a few other gimmicks, the Kindle is still a one-trick pony. But it does that trick — being an e-book reader — superbly well. It offers an excellent reading experience.

We all know that the predominant trend in technology is convergence. The Apple iPad scores so much better in this regard. It's a multi-purpose machine. It's capable of far more than reading books, and it’s larger size and colour screen make it superior for magazines. As an e-book reader it’s let down by being an LCD screen, which is immeasurably less crisp that e-ink and far more tiring on the eyes. When display technology improves, the Kindle's one advantage — ease of reading text — will diminish, perhaps even vanish. But I think we're still a few years from that point. And who knows? Maybe Amazon will expand the capabilities of future versions of the Kindle, making it more into a fully-fledged tablet device.

For the time being, though, for long-form reading, nothing beats the Kindle. And in the end, that's why I decided to buy one. The Kindle concept, as currently conceived, has no future. But that's fine, because I'm using it to read books now, and enjoying the experience immensely.

 

Publishing on Apple's iBookstore - well, that was easy...

Publishing your book for the iPad is straightforward, if you have all your ducks in a row

My first thought when I saw the Apple iPad and its iBooks app was, 'how do I get on it?'. That question has now been answered: Apple has opened up the iBookstore to everyone. But to take advantage of the opportunity, you need to be prepared.

Apple iPad

First, sign up with Apple iTunes Connect. I get the impression that the sign-up process has been designed deliberately to put off casual wannabes. It's fairly detailed and demanding. For example, if you're not a US resident, you'll need an IRS ITIN - I explain here how we got ours.

Make Do & CookNext, you'll need your book in ePub format. And you have to make sure it passes epubcheck with flying colours. I covered a lot of this in my three-part post about fixing InDesign CS3's ePub issues.

Apple wants a separate cover image, not one embedded in the ePub file, so have a hi-res version ready.

Your book also needs an ISBN. For Make Do & Cook and Lady Caine, we decided to create iBookstore editions with their own ISBNs.

Lady 
CaineYou'll be asked to enter various metadata, including a book description. You'll also be asked about the print version of the book (price, number of pages). If you don't have a print version, you need to guess at what it would be like. Strange.

The iTunes Connect website provides forms for uploading the files. But Mac users have a better option. You can download the iTunes Producer software which holds your hand as you go through the various stages of providing information for your book (metadata, pricing, territories, etc) and ensures that all the ducks are in a row before you upload. I highly recommend using this as it helps you understand what information you'll need to have at hand.

Once uploaded, the book needs to be approved. This took about 48 hours for our titles. We then sold our first e-book within a few hours, before we'd even had time to announce that the iPad editions were available.

 

Eating well, spending less

Trish's new book shows how you can create great meals with very little money, simply by getting to understand basic foods

Make Do & CookI'm relieved to find that becoming downshifters doesn't mean giving up good food. Let's face it, I like my food, and while we have cut out visits to expensive restaurants, we continue to eat very well at home.

The reason is that Trish is an excellent cook - not because she does fancy, show-off meals in that irritatingly foodie, "look at me I'm so clever" way: she cooks well because she has taken the time to understand food. That's surprisingly rare these days, when most people think that it isn't food unless it comes out of a packet (ie, people like me).

Now Trish has shared that knowledge. Her new book, Make Do & Cook (published by WebVivant Press) is more than a bunch of recipes (although there's 100 of those). It helps to explain how food works.

Trish covers 10 basic foods - carrots, cabbages, onions, potatoes, pulses, apples, eggs, bread, pasta and rice - and shows you how to use them to best effect. She tells you what to look for, the strengths of each food and how you can use it to create delicious salads, soups, main dishes and - where appropriate - deserts (and some of those will surprise you).

Although there's no meat in the above list, this isn't a vegetarian book (although there are veggie recipes). Meat is expensive, so Trish shows you how to use it sparingly, so you can enjoy the taste of meat without wasteful spending.

All of the above comes in the second part of the book. The first part lays the groundwork. Eating well on a budget may involve a change in how you approach food.

Trish offers tips on shopping (how price points work, when to spend and when to save, and how to spot bargains). She helps you plan your meals so that you can budget properly. She tells you what you should have in your store cupboard, and also what equipment you need (and what you don't). There's a chapter on economical cooking methods and another on stocks and soups, the basis of many tasty but cheap meals.

Many of the ideas and recipes in the book are based on peasant cuisines from around the world. These dishes are created from basic ingredients using simple cooking techniques. But as any fan of, say, Indian or Moroccan food will know, the end results are wonderfully delicious.

And because Make Do & Cook steers you away from packaged and processed foods towards real ingredients, the meals are also far more nutritious and healthy. 

Kindle editionMake Do & Cook is available in both print and Kindle e-book editions (with other e-book versions due soon).

If you follow its advice, you'll save the cost of the book the first time you go shopping.

Armed with the knowledge of how to cut out waste and use basic foods to their fullest potential, you'll soon find you're spending much less on meals. But what you won't be giving up is delicious food.

 

Savvy ShoppingSavvy Shopping

Some of this information is available for free - in a downloadable e-book: Make Do & Cook: Savvy Shopping. This is adapted from the chapters on shopping, budgeting and menu planning in Make Do & Cook, and will help you start saving money even before you get into the kitchen.

This free e-book is available in most formats. The PDF and ePub editions are available for direct download from the WebVivant Press site, while other editions are available via Smashwords.

 

Fixing Adobe InDesign CS3's ePub files (part 3)

The third part of our article of correcting InDesign CS3's ePub files looks at the toc.ncx file and CSS

« Part 1 - Introduction
« Part 2 - Fixing the content.opf file 

 

In this final instalment, we look at editing the table of contents file, toc.ncx, part of the ePub file package, as well as taking a quick look at CSS. Our examples are based on the files created for our recent free e-book, Make Do & Cook: Savvy Shopping.  

Editing toc.ncx 

Savvy ShoppingThe toc.ncx file is the publication's table of contents. Like the content.opf file we dealt with in the previous post, it too is an XML file which you can edit with any plain-text editor (such as Notepad).

And also like the content.opf file, we've got two jobs to do here - fix InDesign CS3's errors and improve slightly on its output. The file produced by InDesign fails to meet the requirements laid out here.

Here's what the toc.ncx file for Savvy Shopping, produced by InDesign CS3, looks like (as before, the bits in square brackets are my comments, not part of the file):

<ns:ncx xmlns:ns="http://www.daisy.org/z3986/2005/ncx/">
  <ns:navMap>
    <ns:navPoint>
      <ns:navLabel>
        <ns:text xmlns:ns="http://www.daisy.org/z3986/2005/ncx/">Cover</ns:text>
      </ns:navLabel>
      <ns:content src="Cover.html"/>
    </ns:navPoint>
    <ns:navPoint>
      <ns:navLabel>
        <ns:text xmlns:ns="http://www.daisy.org/z3986/2005/ncx/">Title_Page</ns:text>
      </ns:navLabel>
      <ns:content src="Title_Page.html"/>
    </ns:navPoint>
    [... repeated navPoint tags for subsequent chapters ...]
  </ns:navMap>
</ns:ncx>

All entries use the ns: namespace. There is an all-encompassing <ncx> tag. Inside that is a <navMap> tag. And inside that are repeated <navPoint> tags - one per chapter.

Inside each <navPoint> tag there's a label tag which provides text for contents table or 'spine' features in e-readers. For example, this text provides the links in the left-hand column in this example, using Adobe Digital Editions:

Savvy Shopping ADE

InDesign produces this table of contents if you use its 'book' feature, where each section is created as a separate file. You then output the ePub document from the book window.

Actually, if you look closely, you'll see that the contents of the <navLabel> tags don't quite match the chapter names in the screenshot above (which is of the amended e-book). InDesign replaces spaces with underscores. So the one bit of tidying up we do with the toc.ncx file is to put the spaces back. However, don't do this with the names in the <content> tags, such as:

<ns:content src="Title_Page.html"/>

(These are self-terminating tags, in that there is no separate closing tag, but there is a forward slash at the end). The contents of these tags are filenames and have to remain unaltered.

Compliance issues

The remaining tasks are to make the toc.ncx file standards compliant.

First, we edit the opening <ncx> tag. This needs the attribute version="2005-1", and you can also take the opportunity to add the appropriate language setting (see the previous post for more info). So our version looks like this:

<ns:ncx xmlns:ns="http://www.daisy.org/z3986/2005/ncx/" xml:lang="en-GB" version="2005-1">

Next, we add two new sections, immediately after the <ncx> tag and before the opening <navMap>.

<ns:head>
    <ns:meta name="dtb:uid" content="{unique-ID}"/>
    <ns:meta name="dtb:depth" content="1"/>
    <ns:meta name="dtb:totalPageCount" content="0"/>
    <ns:meta name="dtb:maxPageNumber" content="0"/>
</ns:head>
<ns:docTitle>
    <ns:text>{book-title}</ns:text>
</ns:docTitle>

Within the <head> section, the first two items are mandatory. The content of the unique ID part should match the string you used in the content.opf file - eg, an ISBN.

The depth setting reflects how many branches there are on the tree structure of the table of contents. If you have a simple list of chapters, then you use 1. If you have sub-sections nested inside chapters, you'd use 2. If there are sub-sections of sub-sections, then it's 3, and so on.

The totalPageCount and maxPageNumber apply only to documents in which rigid pagination is enforced. This doesn't apply to the vast majority of e-books, where text is designed to be fluid. So you could leave out these entries or set them to 0, as we have here.

Obviously, you'll need to put your own book's title in place of {book-title}.

The remaining step is more tedious and time-consuming. Every opening <navPoint> tag should have two attributes, id and playOrder.

The id attribute is a unique identifier for the specific <navPoint> tag. It should be simple, with no spaces or punctuation. A version of the chapter title would do fine. So, if this is the <navPoint> tag for Chapter 1 of your book, an id of chapter1 would work fine.

The playOrder attribute simply specifies the order of the chapters. So, in our example above, we would have:

<ns:navPoint id="cover" playOrder="1">
   <ns:navLabel>
      <ns:text xmlns:ns="http://www.daisy.org/z3986/2005/ncx/">Cover</ns:text>
   </ns:navLabel>
   <ns:content src="Cover.html"/>
</ns:navPoint>
<ns:navPoint id="titlePage" playOrder="2">
   <ns:navLabel>
      <ns:text xmlns:ns="http://www.daisy.org/z3986/2005/ncx/">Title Page</ns:text>
   </ns:navLabel>
   <ns:content src="Title_Page.html"/>
</ns:navPoint>

With these changes, your ePub e-book should sail through epubcheck with flying colours.

The CSS file

There's also a CSS file in the ePub package, called template.css. This provides the styling for the book, including setting fonts. This is a whole subject in itself, but there are just a couple of observations to be made here.

InDesign CS3 doesn't generally embed the fonts in the ePub package. It creates a CSS file that assumes the fonts specified in the InDesign paragraph and character styles will be found on the user's machine. That ain't necessarily so.

Unfortunately, it doesn't specify 'fallback' fonts should the user not have the fonts you wanted. It's worth fixing that.

One way is to edit the template.css file for each book. Open it in a text editor. Ignore the opening sections which start, @font-face. But in the main section, where the styles are defined for each paragraph style, add a fallback font wherever you see 'font-family' used.

For example, InDesign produced the following for Savvy Shopping:

p.headings-titlepagebooktitle {
    font-family: "Adobe Garamond Pro";
    [... other stuff ...]
}

There's no fallback should users not have Adobe Garamond Pro on their machines. So we change this to:

    font-family: "Adobe Garamond Pro", serif;

In that case, the user's machine will use its default serif font, whatever that may be. Don't be tempted into entering long lists of your favourite fonts. Just use serif, sans-serif, cursive or monospace as appropriate. (You could use 'fantasy' too, but that could produce some nasty effects.)

We've eased this burden by creating an all-purpose CSS file for all our books. We created an InDesign document that uses all the paragraph and character styles we've defined for our print books. Then we modified these styles, selecting very common fonts (Times New Roman for serif, Arial for sans-serif), output an ePub package and then edited the template.css file, making slight adjustments and adding the generic fallback fonts.

Now, whenever we output an e-book from InDesign, we simply replace the template.css file with our standard one. That means we can have any fonts and font sizes in the InDesign layout we want, giving us great flexibility in the design for the print version. These are all replaced with settings more appropriate to e-books simply by replacing the template.css file.

 

Resources:

 

« Part 1 - Introduction
« Part 2 - Fixing the content.opf file 

 

Fixing Adobe InDesign CS3's ePub files (part 2)

Correcting errors and adding new entries in the content.opf file to make e-books created with InDesign CS3 more compliant

« Part 1 - Introduction
» Part 3 - Fixing the toc.ncx file and CSS

In this second instalment, we look at editing the content.opf file - part of the ePub file package. Our examples are based on the files created for our recent free e-book, Make Do & Cook: Savvy Shopping.

Editing content.opf

TSavvy Shoppinghe content.opf file is the main metadata file describing the publication and its overall structure. It's an XML file, and if you don't know what that is, you may want to do some Googling on the subject first. The key thing to know is that XML uses tags inside angle brackets, much as HTML does. And like HTML, these tags come in pairs, with an opening tag and a closing one that includes a forward slash. Here's a typical line from the content.opf file:

<dc:identifier id="wvp-id" opf:scheme="ISBN">1441493379</dc:identifier>

This is the <identifier> tag. Its name is prefixed with 'dc:' (which stands for Dublin Core - a metadata standard). Such prefixes are known as namespaces, and if that term is new to you too, then it's time for more Googling. This tag also has attributes, additional bits of information that go inside the tag.

As content.opf is just a plain text file, you can open it with your favourite text editor. Make sure you use a text editor and not a word processor - you want something that can save ordinary text files. I use TextWrangler and Komodo Edit on the Mac. On Windows, you could use Notepad. Linux users are spoiled for choice (Kate was always my favourite).

Here are the highlights from the content.opf file as produced by InDesign (the bits in square brackets are my notes, not part of the file:

<?xml version="1.1"?>
<package xmlns="http://www.idpf.org/2007/opf" version="2.0">
  <metadata xmlns:dc="http://purl.org/dc/elements/1.1/">
    <dc:title>Make Do &amp; Cook: Savvy Shopping</dc:title>
    <dc:creator>Patricia Mansfield-Devine</dc:creator>
    <dc:subject>shopping</dc:subject>
    <dc:subject>cooking</dc:subject>
    [... ditto for several other subjects ...]
    <dc:description>Shop the smart way so you can enjoy delicious and nutritious meals on the smallest budget.</dc:description>
    <dc:rights>Copyright Patricia Mansfield-Devine. All rights reserved.</dc:rights>
  </metadata>
  <manifest>
    <item id="ncx" href="toc.ncx" media-type="text/xml"/>
    <item id="cover" href="Cover.html" media-type="application/xhtml+xml"/>
    <item id="mdc-cover-front-fmt-jpeg" href="images/MDC_Cover_Front_fmt.jpeg" media-type="image/jpeg"/>
    <item id="mdc-savvyshopping-cove-fmt-jpeg" href="images/MDC_SavvyShopping_cove_fmt.jpeg" media-type="image/jpeg"/>
    <item id="title-page" href="Title_Page.html" media-type="application/xhtml+xml"/>
    <item id="mdc-cover-front-fmt-jpeg-1" href="images/MDC_Cover_Front_fmt.jpeg" media-type="image/jpeg"/>
    <item id="mdc-savvyshopping-cove-fmt-jpeg-1" href="images/MDC_SavvyShopping_cove_fmt.jpeg" media-type="image/jpeg"/>
    <item id="copyright-page" href="Copyright_Page.html" media-type="application/xhtml+xml"/>
    <item id="mdc-cover-front-fmt-jpeg-2" href="images/MDC_Cover_Front_fmt.jpeg" media-type="image/jpeg"/>
    <item id="mdc-savvyshopping-cove-fmt-jpeg-2" href="images/MDC_SavvyShopping_cove_fmt.jpeg" media-type="image/jpeg"/>
    [... ditto for all the other chapters ...]
    <item id="css" href="template.css" media-type="text/css"/>
    <item id="pt" href="page-template.xpgt" media-type="application/vnd.adobe.page-template+xml"/>
  </manifest>
  <spine toc="ncx">
    <itemref idref="cover"/>
    <itemref idref="title-page"/>
    [... ditto for the other chapters ...]
  </spine>
</package>

The metadata section was created by InDesign based on the metabata we entered in the ID file itself. We also used ID's 'book' feature, where each chapter or section of the book is kept in a separate file. This creates a proper table of contents in the ePub file.

There are two problems with this file. First it's missing certain elements that are needed to make the file fully standards compliant. This is the source of that worrying message: 'The document appears to have minor errors that might cause it to be displayed incorrectly'. And second, there are additional elements we would like in there.

Compliance issues

We're going to be using some XML namespaces not already referred to in the document. So our first job is to edit the <metadata> tag on line 2. Here's how it ends up:

<metadata xmlns:dc="http://purl.org/dc/elements/1.1/"
    xmlns:dcterms="http://purl.org/dc/terms/"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:opf="http://www.idpf.org/2007/opf">

The opening <package> tag should contain an element called 'unique-identifier'. This is actually a pointer to the <identifier> tag we met earlier. As you can see, that tag included the attribute id="wvp-id". So in this case, the <identifier> tag has an id of 'wvp-id'. You can choose whatever value you want for the id (ours is short for WebVivant Press ID), but it pays to be consistent. All of our books will use 'wvp-id'.

So, we edit the opening <package> tag to read:

<package unique-identifier="wvp-id">

And then we add the <identifier> tag to the metadata section. It can come anywhere in that section, so long as it's between the metadata opening and closing tags.

<dc:identifier id="wvp-id">{unique-id}</dc:identifier>

You need to replace the {unique-id} bit with something, well, unique. Unique, that is, to this book. If your book has an ISBN, you could use that, in which case you can also add the attribute, opf:scheme="ISBN". Here's what the tag looks like with an ISBN:

<dc:identifier id="wvp-id" opf:scheme="ISBN">1441493379</dc:identifier>

Because Savvy Shopping doesn't have an ISBN, we went with:

<dc:identifier id="wvp-id">WVP201002-Savvy-Shopping</dc:identifier>

Further down the file, in the <manifest> section, InDesign assigns the wrong mimetype to the 'ncx' table of contents entry. It says:

<item id="ncx" href="toc.ncx" media-type="text/xml"/>

In fact, it should be:

<item id="ncx" href="toc.ncx" media-type="application/x-dtbncx+xml"/>

There's one final problem. In the manifest section, you'll see that each chapter file gets its own entry. The same goes for the images used in the book. Now, Savvy Shopping has only two images - one used as the cover and one used inside. But references are created to these images with every chapter. Here's what the lines look like for the first two 'chapters' - the cover and the title page:

<item id="cover" href="Cover.html" media-type="application/xhtml+xml"/>
<item id="mdc-cover-front-fmt-jpeg" href="images/MDC_Cover_Front_fmt.jpeg" media-type="image/jpeg"/>
<item id="mdc-savvyshopping-cove-fmt-jpeg" href="images/MDC_SavvyShopping_cove_fmt.jpeg" media-type="image/jpeg"/>
<item id="title-page" href="Title_Page.html" media-type="application/xhtml+xml"/>
<item id="mdc-cover-front-fmt-jpeg-1" href="images/MDC_Cover_Front_fmt.jpeg" media-type="image/jpeg"/>
<item id="mdc-savvyshopping-cove-fmt-jpeg-1" href="images/MDC_SavvyShopping_cove_fmt.jpeg" media-type="image/jpeg"/>

The second and third lines refer to the images. These lines are fine and need to be kept. But lines 5 and 6 are references to the same images (the 'href' parts are identical) even though the tags get new IDs (by having the -1 suffix added). Indesign did the same with all the other chapters. This is unnecessary and may make e-readers report an error. Certainly, epubcheck doesn't like it. So we deleted all the superfluous image references, keeping only the first reference to each image.

Adding lines

That's it for making the file compliant. Now to add some additional features.

The next step is to add lines to the <metadata> section. Like I said, InDesign has already created a number of entries there. We add:

<dc:publisher>WebVivant Press</dc:publisher>
<dc:language>en-GB</dc:language>
<dc:date xsi:type="dcterms:W3CDTF">{date}</dc:date>

Clearly, you'll want to use your own publisher name. The 'en-GB' entry is for British English. You could use en-US for American English or just en, assuming your book is in English.The contents of this tag need to comply with RFC 3066 (see http://www.ietf.org/rfc/rfc3066.txt).

You need to replace the {date} part with the publication date. For books, the most common formats are YYYY, YYYY-MM or YYYY-MM-DD. The acceptable date formats are defined by 'Date and Time Formats' at http://www.w3.org/TR/NOTE-datetime which is based on ISO 8601. We prefer to go with month and year, so the entry for Savvy Shopping looks like this:

<dc:date xsi:type="dcterms:W3CDTF">2010-02</dc:date>

The <creator> tag works as it is, but we add a little extra information - data that helps systems sort and store the document and what role the creator played in this case. So our tag looks like this:

<dc:creator opf:file-as="Mansfield-Devine, Patricia" opf:role="aut">Patricia Mansfield-Devine</dc:creator>

In the references below, you'll find lots more info about roles, and also the optional <contributor> tag.

Finally, in the <rights> tag we fix that copyright symbol problem by adding the &#169; entity, so it looks like this:

<dc:rights>Copyright &#169; Patricia Mansfield-Devine. All rights reserved.</dc:rights>

And that's it for the content.opf file. 

In the final part, we'll look at correcting the toc.ncx file and have a quick discussion about CSS.

 

Resources:

« Part 1 - Introduction
» Part 3 - Fixing the toc.ncx file and CSS

 

 

Fixing Adobe InDesign CS3's ePub files (part 1)

InDesign allows you to create ePub e-book files direct from your book's page layout. But it has its problems. Here's how to correct them

Joining forces

A new group for authors in France's Grand Ouest region - Brittany, Normandy and the Pays de la Loire

Zipping ePub files

The ePub file format is just a zip file. But you have to be careful how you construct it

More e-book trouble for Amazon

Two more publishers are dictating higher e-book prices, deserting Amazon's $9.99 model

Let the tablet wars commence

Google has an ideal tablet operating system and a huge investment in e-books. It could give the Apple iPad a run for its money, at least in the publishing world

The iPad effect - loosening Amazon's grip

The book trade has long complained about Amazon's death-grip on prices and margins. Maybe the iPad has changed the balance of power

Tags:

Why the iPad may be good news for self-publishers

And, perhaps, the death knell of Amazon's Kindle

Creating e-books - part 2

In Part 1 we covered e-book formats, services and a production workflow. Now let's look at a few issues concerned with actually creating the files.

Creating e-books - part 1

The e-book is an important format - but how do you go about creating one?

E-books - the slow revolution

It's been fun dismissing the e-book as a gimmick. Now we must embrace it as the format of the future. For self-publishers, it's time to put the e-book first