Search:

Apache » Lenya
project logo
  • Project
  • Developer
  • Community
  • Version 2.0
  • Version 1.2
  • Version 1.2
    • Installation
      • Download
      • Subversion Access
      • Install Instructions
    • Tutorial
      • Introduction
      • 1. Understanding Lenya
      • 2. Installing Lenya
      • 3. Anatomy of the Pipeline
      • 4. Editing in Lenya
      • 5. Custom Navigation in Lenya
      • 6a. Mod Proxy and Lenya
      • 6b. Mod Proxy and Lenya
    • How-To
      • FAQ
      • New Publication
      • Deploy Publication
      • Look and Feel
      • Custom Resource Type
      • Adding Mime Types
      • Site Navigation
      • LDAP Authentication
      • CMS Menus
      • CMS Screens
      • Search Publications
      • External Data
      • Unit Tests
    • Components
      • Access Control
        • Basic Terms
        • Access Controllers
        • Access Controller Resolvers
        • Authenticators
        • Authorizers
        • Policies and Policy Managers
        • Accreditable Managers
        • SSL Encryption
      • Authoring
        • Adding a new document creator
        • Image Upload
        • OpenOffice
      • Deployment
        • Proxying
      • Editors
        • HTML Form Editor
        • HTML One Form Editor
        • Bitflux Editor
        • Kupu
        • Xopus
      • Layout
        • Navigation
        • XHTML templating
        • Serving static resources
        • Lenya Menubar
      • Publication
        • PageEnvelopeModule
        • Site tree
      • Resource Types
        • Resource Types
      • Revision Control
        • Revision Controller
        • RCML
        • Check In
        • Check Out
        • Revisions
        • Rollback
      • Repository
        • WebDAV Servers
      • Search
        • Searching with Lucene
      • URI Handling
        • URI Parametrizer
        • URI Scheme
        • Usecases
      • Asset Management
        • Asset Management
      • Link Management
        • Link Management
      • Meta Data
        • Meta Data Handling
      • Multilingual Documents
        • Multilingual Document Handling
      • Tasks
        • The Task Concept
        • Defining Tasks
        • The TaskAction
        • Scheduling a Task
        • Included tasks
          • AntTask
          • DefaultFilePublisher
          • StaticHTMLExporter
          • MailTask
        • Developing Tasks
      • Workflow
        • Terms
        • The State Machine
        • Configuration
        • Implementation
      • Site Management
        • Archive
        • Copy
        • Deactivate
        • Delete
        • Delete the trash
        • Move
        • Move Up/Down
        • Rename
        • Restore
    • Miscellaneous
      • Namespaces
      • Reserved Names
      • XInclude Processor
    • 1.2 API (Javadoc)

Current Event

Built with Apache Lenya

CMS Screens How-To

Table of Contents
  • File Locations
  • Sitemap Usage
  • Writing a CMS screen
  • Cascading Stylesheets

A CMS screen is an HTML page that belongs to the Lenya CMS, not to a specific publication (this is the reason for choosing the term "screen" instead of "page"). Typical examples are site administration screens and confirmation screens.

File Locations

  • src/webapp/lenya/xslt/util/page2xhtml.xsl - The CMS screen stylesheet.

  • src/webapp/lenya/resources/css - The CMS screen CSS files.

Sitemap Usage

Usually a resource is used to style a CMS screen:

<map:resource name="style-cms-page">
  <map:transform src="lenya/xslt/util/page2xhtml.xsl">
    <map:parameter name="contextprefix"
                   value="{request:contextPath}"/>
  </map:transform>

  <map:serialize/>
</map:resource>

¨ This resource is called from the pipeline (the example serves the Lenya CMS starting page):

<map:match pattern="index.html">
  <map:aggregate element="lenya" ...>
    <map:part src="cocoon:/publications.xml"/>

    <map:part src="lenya/content/introduction.xml"/>
  </map:aggregate>
  <map:transform src="lenya/xslt/util/welcome.xsl"/>
  <map:call resource="style-cms-page"/>
</map:match>

Writing a CMS screen

To write a CMS screen, use the following syntax:

<page:page xmlns:page="http://apache.org/cocoon/lenya/cms-page/1.0">

  <page:title>
    <!-- the page title (used for HTML title and heading) -->
  </page:title>

  <page:body>
    <!-- put your XHTML here -->
  </page:body>

</page:page>

Cascading Stylesheets

When using CSS classes or IDs, please follow the rule that every class or ID starts with the prefix lenya-.

Put your specific CSS file in the CSS directory (see above) and include it in default.css.

Currently, the following Lenya CSS classes are defined:

  • Boxes

    • div.lenya-box

    • div.lenya-box-title

    • div.lenya-box-body

  • Forms

    • td.lenya-entry-caption

    • .lenya-form-element

  • Tables

    • table.lenya-table

    • table.lenya-table-noborder

    • table.lenya-table th

    • table.lenya-table td

    • table.lenya-table-noborder td

  • Tabs

    • .lenya-tab

    • .lenya-tablink

  • Antlog

    • .lenya-ant-bannercell

    • table.lenya-ant-status

    • .lenya-ant-error

    • .lenya-ant-warn

    • .lenya-ant-info

    • .lenya-ant-debug

    • .lenya-ant-failed

    • .lenya-ant-complete

    • .lenya-ant-a td

    • .lenya-ant-b td

  • Misc

    • .lenya-body

    • .lenya-project-logo

    • td.lenya-content

    • td.lenya-sidebar

    • td.lenya-frontpage

    • .lenya-page-title

    • .lenya-page-subtitle

    • .lenya-publication-item

    • .lenya-sidebar a

    • .lenya-sidebar-heading

Copyright © 1999-2011 The Apache Software Foundation. All rights reserved.

Apache Lenya, Apache, and the Apache feather logo are trademarks of The Apache Software Foundation.