Example - Accessible EPUB 3

This page provides specific information regarding the EPUB variant used in "EPUB 3 Best Practices".

Overview

The EPUB variant used by this book largely matches that described in EPUB 3 Best Practices, but there are some exceptions.

Note: Per the EPUB 3 Samples Table page, this document is licensed under Creative Commons Attribution-ShareAlike Unported (CC BY-SA 3.0). So (for example), we can make it available for field testing on our demonstration web server.

Because this is an EPUB 3.0 document, it has a NAV file (newly defined in EPUB 3). However, it does not have an NCX file (required for backward compatibility with EPUB 2). The Nav file (bk01-toc.html) covers the Chapter and Section levels.

Details

O'Reilly produces a large number of high-quality technical reference works for software developers. Let's examine their EPUB archive for Accessible EPUB 3.

Directory Tree

The file tree contains about 100 files, about two dozen of which (e.g., HTML) reside in the EPUB directory (tsk). The images reside in the EPUB/covers and EPUB/images directories.

.../ex_ae3/tree/
| EPUB/                    # EPUB content
| | bk01-toc.html          # Table of Contents (HTML)
| | ch??.xhtml             # chapter pages (HTML)
| | ch??s??.xhtml          # section pages (HTML)
| | co01.xhtml             # colophon page (HTML)
| | cover.xhtml            # cover page (HTML)
| | covers/*.jpg           # cover images (JPEG)
| | css/*.css              # Cascading Style Sheets (CSS)
| | fonts/*.woff           # Compressed fonts (WOFF)
| | images/                # raster image files
| | | *.png                # PNG files (1)
| | | web/*.png            # PNG files (1)
| | index.xhtml            # index header page (HTML)
| | lexicon/*.pls          # pronunciation lexicon (XML)
| | package.opf            # Open Packaging Format (XML)
| | pr??.xhtml             # preface pages (HTML)
| | pr??s??.xhtml          # preface section pages (HTML)
| | spi-ad.xhtml           # SPi Global advertisement (HTML)
| META-INF/                # EPUB metadata
| | container.xml          # media type, paths (XML)
| mimetype                 # "application/epub+zip"

Package Document

Per META-INF/container.xml, EPUB/package.opf is our package document. This is a substantial file (82 lines), so here's another summary:

package       # prefix, unique-identifier, version, xmlns
| metadata    # xmlns:dc, xmlns:opf
| | dc:*      # creator, identifier, language, ...
| | meta      # property="dcterms:modified"
| manifest    # list of files included in document
| | item      # id, href, media-type
| | ...
| spine       # ordered list of files
| | itemref   # idref=cover, linear=no
| | itemref   # idref=spi_ad
| | itemref   # idref=id-id2442754
| | itemref   # idref=htmltoc, linear=yes
| | itemref   # idref=id-id2632344
| | ...

Spine

The spine entry lists the enclosed content files, in the "normal" reading order. Note that there is no guide section.

The OEBPS/package.opf file contains one indications that bk01-toc.html is the Nav file:

  • the manifest entry for item htmltoc

bk01-toc.html is an XHTML file, which guarantees some useful syntactic decorum (e.g., closing tags).


This wiki page is maintained by Rich Morin, an independent consultant specializing in software design, development, and documentation. Please feel free to email comments, inquiries, suggestions, etc!

Topic revision: r2 - 28 Oct 2016, RichMorin
This site is powered by Foswiki Copyright © by the contributing authors. All material on this wiki is the property of the contributing authors.
Foswiki version v2.1.6, Release Foswiki-2.1.6, Plugin API version 2.4
Ideas, requests, problems regarding CFCL Wiki? Send us email