I'm presently using Spring 3.0.4
and Apache Tiles 2.2.2
in my web app. I'd like to replace JSP with Apache Velocity 1.6.3
but I'm somewhat confused on how to do this. Ultimately, I'd like to be able to do the following in a Tiles definition:
<definition name="basicLayout" template="/WEB-INF/layout/basicLayout.vm">
<put-attribute name="header" value="/WEB-INF/layout/header.vm" />
<put-attribute name="content-area" value="/WEB-INF/layout/content.vm" />
<put-attribute name="footer" value="/WEB-INF/layout/footer.vm" />
</definition>
Is this possible? If so, do I need to create any custom view classes to support it? I'm currently using the standard Spring VelocityConfigurer, TilesConfigurer, VelocityView, TilesView classes.
Thanks!
I've created helper classes which include tiles integration with velocity: https://github.com/pete911/openhouse-web there's a descritption when you scroll down. classes can be found in maven central as well.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With