Jeremy Stein - Brain

« »

Sitemesh PageDecoratorMapper

When configuring Sitemesh to use the PageDecoratorMapper, you have to follow it with the ConfigDecoratorMapper. The PageDecoratorMapper will map to a decorator name, but then Sitemesh continues down the chain looking for a definition for that decorator, which is provided in the config file (usually decorators.xml) for ConfigDecoratorMapper.

  <mapper class="com.opensymphony.module.sitemesh.mapper.PageDecoratorMapper">
    <param name="property.1" value="meta.decorator" />
    <param name="property.2" value="decorator" />
  <mapper class="com.opensymphony.module.sitemesh.mapper.ConfigDecoratorMapper">
    <param name="config" value="${decorators-file}"/>

April 2, 2007 1 Comment.

One Comment

  1. Rick replied:

    Thanks for the tip. This helped fix my problem.
    Sitemesh is an OK tool, but its documentation is really, really poor.

    June 21st, 2008 at 11:44 am. Permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

Why ask?

« »