This is a collection of Velocimacros that are meant for use with VelocityStruts applications. these will generally make use of the VelocityStruts tools (using their recommended keys of course!), but needn't necessarily do so.


This macro can be used in vm files used as Tiles templates when the VelocityViewServlet is added in the Struts 1.1. application. It renders the value of the template attribute stored by the <put name="attribute" value""/> in the tiles-defs.xml. Enjoy.

#macro (tilesAttribute $attribute)
	$request.getAttribute("org.apache.struts.taglib.tiles.CompContext").getAttribute($attribute)
#end
  • No labels