Skip to end of banner
Go to start of banner

Run Macro - 6.x

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 17 Next »

On this page

Description

The run macro provides a form with specified input fields, settings, and parameters that you define within the editor. The values input into the form fields will be used to replace variables in the body of the Confluence page before it is rendered. Form values can be provided as:

  1. User interaction - a user inputs data into the fields you've defined.
  2. By using Pre-defined variables.
  3. By including request parameters (from the URL).

Any text in the body of the run macro will be replaced by:

  • the value when the text begins with '$' immediately followed by a key found in the replace parameter list  (see Field types for details). Typically, values will be provided by a user submitting a form from the page based on the replace parameter. When defining field types, default values may be specified.
  • dynamic text using any Field key parameters that begin with '$' followed by a Field key. 

Variables

Use the run macro

The following steps will help demonstrate the most common method of introducing the run macro to a Confluence page.

Encode variables

You might want to encode run macro variables before rendering the output. Use urlencode or base64 encoding options with a prefix '$variable_' in the macro body to encode the intended variable. For example, use $alist_base64 to endcode the alist variable.

Work with field settings

With the run macro on our Confluence page, it's time to explore adding fields to a form.

  • No labels