Configuration

 Last change: December 31. 2001
 
Home > Configuration
Automatic Handling of Velocity Templates

To enable automatic processing of Velocity templates files (*.vm files), the following statements have been added to the web application configuration file (WEB-INF/web.xml)

  <!-- Define Velocity template compiler -->
<servlet>
<servlet-name>velocity</servlet-name>
<servlet-class>org.apache.velocity.contrib.struts.VelServlet</servlet-class>
<init-param>
<param-name>properties</param-name>
<param-value>/velocity.properties</param-value>
</init-param>
</servlet> <!-- Map *.vm files to Velocity -->
<servlet-mapping>
<servlet-name>velocity</servlet-name> <url-pattern>*.vm</url-pattern>
</servlet-mapping>

 

Gabriel Sidler, sidler@teamup.com