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 that have an @id attribute of "title" and an @id attribute of "content".
  • references is a <document> element with a @type attribute of "references" and two  <section> elements that have an @id attribute of "front" and "xrefs". In the second section is an <xref-fragment id="content"> element. This is a specialized fragment that invokes a link editor instead of a rich text editor. 

On any PageSeeder server, each project can have a set of custom document types that are accessible by 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 config. 

book-document.png

  • 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 pre-defined 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"
                  count="n">
          <value>Lewis Caroll</value>
        </property>
        <property title="Category"
                   name="category"
                  count="n">
          <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