Epub
Epub ist ein speziell für E-Books entwickeltes Format, das auf HTML aufsetzt und die Inhalte zusammen mit Metainformationen und Hinweisen zu Kapiteln in eine Containerdatei packt. Es unterstützt eine flexible Seitendarstellung, die auch Smartphones und Netbooks, also Geräte mit kleineren Displays, unterstützt und dem Benutzer trotzdem mitteilt, auf welcher Seite im gedruckten Text er nun wäre (wichtig für das Zitieren). Epub unterstützt DRM, setzt es aber nicht voraus.
Der eigentliche Inhalt wird entweder im XHTML- oder im DTBook-Format gespeichert.
Beispiel
Das Dateisystem in einer minimalen Epub-Datei könnte so aussehen:
mimetype
META-INF/
container.xml
inhalt.opf
inhalt.ncx
inhalt.xhtml
Dabei können die einzelnen Dateien innerhalb des Zip-Archives folgende Inhalte haben:
mimetype
application/epub+zip
container.xml
<?xml version="1.0" encoding="UTF-8"?> <container xmlns="urn:oasis:names:tc:opendocument:xmlns:container" version="1.0"> <rootfiles> <rootfile full-path="inhalt.opf" media-type="application/oebps-package+xml"/> </rootfiles> </container>
inhalt.opf
Dies ist die Stammdatei. Im Abschnitt manifest werden alle Dateien, die entsprechend der OPF-Spezifikation im Archiv gespeichert werden, aufgelistet. Der Abschnitt spine ist ein minimales Inhaltsverzeichnis, mit dem Attribut toc wird auf das ausführliche Inhaltsverzeichnis verwiesen.
<?xml version="1.0" encoding="UTF-8"?> <package xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:opf="http://www.idpf.org/2007/opf" xmlns="http://www.idpf.org/2007/opf" version="2.0" unique-identifier="BookId"> <metadata> <dc:language xsi:type="dcterms:RFC3066">de-DE</dc:language> <dc:title>Hello World</dc:title> <dc:identifier id="BookId">id_Hello_World</dc:identifier> </metadata> <manifest> <item id="ncx" href="inhalt.ncx" media-type="application/x-dtbncx+xml"/> <item id="Datei_1" href="inhalt.xhtml" media-type="application/xhtml+xml"/> </manifest> <spine toc="ncx"> <itemref idref="Datei_1"/> </spine> </package>
inhalt.ncx
Diese Datei enthält ein detailliertes Inhaltsverzeichnis im Abschnitt navMap. Jedem Eintrag wird im Attribut playOrder eine Position innerhalb der Reihenfolge der wiederzugebenden Texte zugeordnet.
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE ncx PUBLIC "-//NISO//DTD ncx 2005-1//EN" "http://www.daisy.org/z3986/2005/ncx-2005-1.dtd"> <ncx xmlns="http://www.daisy.org/z3986/2005/ncx/" version="2005-1" xml:lang="de-DE"> <head> <meta name="dc:Title" content="Hello World"/> <meta name="dtb:uid" content="id_Hello_World"/> </head> <docTitle> <text>Hello World</text> </docTitle> <navMap> <navPoint playOrder="1" id="id_Hello_World_01"> <navLabel> <text>Hello World</text> </navLabel> <content src="inhalt.xhtml"/> </navPoint> </navMap> </ncx>
inhalt.xhtml
Der eigentliche Inhalt des Beispiel-E-Books, hier als einfache XHTML-Datei.
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <link rel="schema.DC" href="http://purl.org/dc/elements/1.1/"/> <title>Hello World</title> <meta name="DC.identifier" content="id_Hello_World"/> </head> <body> <h1>Hello World</h1> <p>Ein Beispieltext.</p> </body> </html>
Software
- Stanza ist ein Epub-Reader für das iPhone und als Stanza Desktop eine Konvertierungssoftware für den Mac, die diverse Formate in das Epub-Format umwandelt.
Literatur und Links
- EPUB in der Wikipedia
- Dr. Oliver Diedrich: Der kleine E-Autor. E-Books im Epub-Format selbst erstellen, c't Heft 25 (2009), S. 146 - 151
Kategorie: Arbeitsmaterial Webworking
Zuletzt angesehen: » Notizblock » GoogleMaps-PlugIn » Epub