Skip to main content

 Documents

Handling and managing documents

Customizing documents

The PageSeeder PSML format has two built-in document types:

  • default – is a <document> element with no @type attribute and two <section> elements, one with an @id attribute value of "title" and one with an @id attribute value of "content".
  • references is a <document> element with a @type attribute value of "references" and two  <section> elements, the first with an @id attribute value of "front" and the second with a value of "xrefs". In the second section is an <xref-fragment id="content"> element, which invokes a link editor instead of a rich text editor. The documents linked into this section provide the Table of Contents (ToC).

Each project on a PageSeeder server can have their own custom document types available to any group in the project. 

Document types provide for customizing of the metadata and content structure, creation and editing, importing and publishing, display and validation.  All these document facets are configurable through various PSML configuration files that are stored in the folder structure under a given document type.

Document type example

Following is an example that illustrates some of the features available through customization using the document type and document configuration. 

Document type – Book example

  • It consists of <section> elements with  @title, @metadata and @overview attributes respectively on each.
  • The fragment in the @metadata section invokes the PSML Properties Editor and the list of valid categories can be customized with a PSML editor config file.
  • Using a configuration defined in the <creation> element, the location of the document files could be constrained to a predefined path and naming pattern such as:
books/00/B001-book.psml

The PSML for this document follows:

<document type="book" level="portable" >
  <section id="title">
    <fragment id="1">
      <heading level="1">Alice's Adventures in Wonderland</heading>
    </fragment>
  </section>
  <section id="metadata">
    <properties-fragment id="2">
      <property title="ISBN"
                name="isbn"
                value="9781451606270"/>
      <property title="Author"
                name="author"
                multiple="true">
        <value>Lewis Caroll</value>
      </property>
      <property title="Category"
                name="category"
                multiple="true">
        <value>Fantasy</value>
        <value>Science Fiction</value>
      </property>
      <property title="Publisher"
                name="publisher"
                value="Looking Glass Books"/>
    </properties-fragment>
  </section>
  <section id="overview">
    <title>Overview</title>
    <fragment id="3">
      <para>Alice chases a white rabbit into a magical
        world.</para>
    </fragment>
  </section>
</document>
Created on , last edited on