XML technologies / DocBook / Structural elements / Chapters and appendices

(Excerpt from "DocBook-XML: Media-neutral and platform-independent publishing" by Thomas Schraitle)

A book is usually divided into chapters (chapter), possibly with appendices (appendix). Both have the same content model, so the discussion below refers only to chapters, including appendices.

A chapter can contain many child elements, including titles, subtitles, tables of contents, sections and lists. In printed works, chapters normally start on a right-hand page. The following example shows how to mark them up.

Example: Structure of a chapter in DocBook

DocBook 4:

<chapter id="chap.intro" lang="de">
    <chapterinfo>
        <date>11.11.2003</date>
        <orgname>Beispiel AG</orgname> 
        <author>
            <firstname>Lieschen</firstname>
            <surname>Müller</surname>
        </author> 
    </chapterinfo>
    <title>Ein erstes Kapitel</title>
    <para> ... </para>
    <section>
        <title>Ein erster Abschnitt</title>
        <para> ... </para>
    </section>
</chapter>

DocBook 5:

<chapter version="5.0" xmlns="http://docbook.org/ns/docbook" xml:lang="de" xml:id="chap.intro">
    <info>
        <date>11.11.2003</date>
        <orgname>Beispiel AG</orgname>
        <author>
            <firstname>Lieschen</firstname>
            <surname>Müller</surname>
        </author>
    </info>
    <title>Ein erstes Kapitel</title>
    <para> ... </para>
    <section>
        <title>Ein erster Abschnitt</title>
        <para> ... </para>
    </section>
</chapter>

For metadata, DocBook 4 provides the element chapterinfo; DocBook 5 provides info. For further information about metadata, see Metadata.

  

back to top