This page last changed on Apr 22, 2007 by david.soul@atlassian.com.

Example Usage

A variable in velocity looks like this:

$foo

To set a variable:

#set ($message = "Hello")

A basic if statement:

#if ($message == "Hello")
   Message received and is "Hello"
#end
A velocity variable which evaluates to null will simply render as the variable name. See the Velocity User's Guide

Related Content

Basic Introduction to Velocity (Confluence) Labels: velocity-related
Confluence Objects Accessible From Velocity (Confluence) Labels: velocity-related
Confluence rendering pipeline (Confluence) Labels: velocity-related
Customising Layouts (Confluence) Labels: velocity-related, customising-looknfeel
Disable Velocity Caching (Confluence) Labels: velocity-related
Document generated by Confluence on May 01, 2007 19:27