Confluence Docs 3.0 : Form Field Markup for Templates This page last changed on Jun 26, 2008 by smaddox. Templates are written in the same notation as other pages in Confluence with special markup to insert form fields. When a user creates a page using a template that contains form fields, the user will be prompted to key in data. The data will be captured and stored in the new page. Here are the three kinds of form fields supported and the markup to create them:
Text field |
    @VAR@
| Creates a text input field for a variable called VAR.
Text area |
    @VAR|textarea(5,10)@
| Creates a 5 x 10 text-area for a variable called VAR.
Drop down menu |
    @VAR|list(one,two,three,four)@
| Creates a drop-down box containing the values "one", "two", "three" and "four". Note: The values in the drop-down list can only contain letters, numbers and underscores. The dropdown list values cannot include: special characters, such as '&' punctuation marks, such as ':' brackets, such as ')'
Every input field must have a unique name. If you have more than one text input field in the same template with the same name, Confluence will make sure that they all end up with the same value (This is useful if you need the same information in more than one place in the page). For an example, please see Adding a Template.
| Warning There must be no spaces between the @-signs in the markup. This means you can't have items in your drop-down lists that contain spaces.
### Improved Markup The above formatting is the basic markup bundled with Confluence, but two plugins expand on this markup to provide greater functionality. Links to these plugins and a comparison can be found in the Working with Templates Overview. ##### RELATED TOPICS Working with Templates Overview Scaffolding Plugin Zones Plugin Adding a Template Editing a template Creating a Page using a Template Take me back to Confluence User Guide

Document generated by Confluence on Nov 05, 2009 23:36