Introduction

When editing Confluence content, "macros" are bits of dynamic or specially formatted content, best entered by typing '{' and waiting for the popup: 

For instance, Table of Contents macro looks for headings in your page, and constructs a nice ToC from them:

User Macros

Most of the available macros are either built-in (e.g. Table of Contents) or provided by plugins, but Confluence also lets administrators create their own quick and dirty macros, called User Macros ("user" from the point of view of some Confluence developer, to whom non-developer = "user").

User Macros are written in Velocity, a language designed for generating text from templates ("Hello $name", etc). The theory is that real programming should be done in Java, and the results exposed as $objects in Velocity, which is responsible solely for text rendering. This means Velocity has minimal "programming" features, and attempts to do real programming in Velocity is Frowned Upon and highly painful.

Nowhere near as painful, however, as writing a full-blown Confluence plugin to achieve the same task. And thus we have this section, a collection of useful, though inadvisably complex, user macros. Enjoy!