list-data

{list-data}

Plugin: Scaffolding Plugin

Allows selection of one or more options from a specific list.

Description

Must contain option-generating sub-macros (e.g. list-option or content-options).

Usage

{list-data:Name|type=[select, check]|multiple=[true, false]}
{xxx-options}
{list-data}

Parameters

Name Required Default Description
[default]/name
The name of the field.
type
select
The type of field to display. May be one of the following:
  • select - (default) A selectable list is displayed.
  • check - A list of checkable items are displayed.
multiple
false
If true, multiple options may be selected.
width
The width of the field. Any CSS width is allowed (e.g. 100px). Note: Only applies when type is 'select'.
height
The height of the field. Any CSS height is allowed (e.g. '20px'). Note: Only applies when type is 'select'.
required
false
If true, a non-empty item must be selected.
separator
(Since Scaffolding 2.3.2) If multiple items are selected, the type of separator to display between each item. Defaults to one item per line. May be one of the following:
  • bracket - Square brackets ('[', ']') surrounding each item.
  • brace - Braces ('{', '}') surrounding each item.
  • comma - A comma (',') between each item.
  • paren - Parentheses ('(', ')') surrounding each item.
  • pipe - A pipe ('|') between each item.
  • newline - A line break after each item.
  • "custom" - Any other character you wish, specified between quotes.
blank
false
If 'true', a blank item is added to the list. Only applies to 'select' lists. If the user saves while selecting the blank item and the list is 'required', the page cannot be saved.
blankText
If specified, and 'blank' is true, this text will be used for the blank option label. E.g. 'blankText=[None]'

Examples

Plain list options

Number: {list-data:List}
{list-option}One{list-option}
{list-option}Two{list-option}
{list-option}Three{list-option}
{list-data}

Wikified list options

Emoticon: {list-data:Emoticon}
{list-option:Star}(*){list-option}
{list-option:Plus}(+){list-option}
{list-option:Minus}(-){list-option}
{list-data}

See Also

Labels

macro macro Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.