velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Scott Farquhar <>
Subject Re: Template inheritance
Date Mon, 19 May 2003 04:31:55 GMT

Nathan Bubna wrote:
> Dirk said:
> Velocity doesn't give you the ability to extend templates in such a
> manner, nor is such a feature planned AFAIK.  since you appear to be
> creating a webapp, i recommend checking out the jakarta-velocity-tools
> project.  it provides a VelocityLayoutServlet that can offer
> functionality somewhat similar to this.  with it you would define one
> (a default) or more "layout" templates analagous to your master
> template, and "body" or "screen content" templates would be able to
> set variables for the layout.  the screen template could also override
> (even dynamically, if you want) the layout to be used if the default
> one is not desired.
> anyway, you can check the project out and build the docs yourself, or
> peruse them online first at
> we haven't gotten them up on the main jakarta site yet.

To second alternative approaches for web-apps, can I suggest Sitemesh? 
It does a similar thing to what you are suggesting (decorating of whole 

Whilst not integrated with velocity (yet!), you can achieve your results 
by using the VelocityServlet.



Expert J2EE Software, Services and Support
Need a simple, powerful way to track and manage issues?
Try JIRA -

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message