Skip to content
OpenCms documentation
OpenCms documentation

Editor field description for Dynamic function

Special elements that programmatically create dynamic content.

Tab "Basic configuration"

Display name
(Text input)
The user-readable name of the formatter.
Formatter key
(Text input)
Optional
The formatter key is stored in container pages as reference to this formatter. This allows to replace e.g. the formatter JSP by configuration, without the need to change container pages that use the formatter. If the formatter key is not set, the UUID of this formatter is stored in container pages instead.
Formatter key must only consist of characters A-Z, a-z, 0-9, /, #, minus (-) or period (.)
Formatter key alias
(Text input)
Optional - Can occur as often as necessary
A deprecated formatter key that should still be mapped to this formatter, but not written to container pages.
JSP
(File selection)
The JSP used to format the content
Description
(Text input)
Optional
Description of the formatter. You can use %(key...) macros here for localization.
Matching containers
Choice
Optional

The container types for which this formatter can be used.

As an option for older templates and formatters a container pixel width can be defined.

Choice option 1
Container types
Optional
Use this formatter for the matching container types.
Container type
(Text input)
Optional - Can occur as often as necessary
A container type for which this formatter can be used.
Choice option 2
Container pixel width
Optional
Use this formatter based on the container pixel width.
Width
(Text input)
Minimum width of the container
Maximum width
(Text input)
Optional
Maximum width of the container
Remove unused nested containers
(Check box)

This is applicable only for formatters generating nested containers.

Changes are only applied when a container page using this formatter is modified in the page editor.

If this is checked, the content in the generated nested containers will be removed from the page if the element is removed from the page OR a nested container is not longer generated by the formatter. This is usually the expected behavior.

If this is not checked, the content in the generated nested containers is kept on the page even if the element is removed from the page OR different nested container structures are generated by the formatter depending on external factors. A use case for this is a formatter that dynamically generates different nested container structures for mobile and desktop devices.

CSS includes
Choice
Optional
CSS files or snippets used by this formatter.
Choice option 1
Inline styles
(Text area)
Optional
A snippet of CSS to style this formatter's output.
A link to a CSS file to style this formatter's output.
Javascript includes
Choice
Optional
Javascript files or snippets used by this formatter.
Choice option 1
Inline script
(Text area)
Optional
A snippet of Javascript used by this formatter.
A link to a Javascript file used by this formatter.
Plugin
Optional - Can occur as often as necessary
Group
(Text input)
Target
(File selection)
Order
(Text input)
Optional
Attribute
Optional - Can occur as often as necessary
Key
(Text input)
Value
(Text input)

Tab "Supported settings"

Element setting defaults
(File selection)
Optional - Can occur as often as necessary
A configuration file containing default values for element settings.
Setting
Optional - Can occur as often as necessary
Used to configure the output generated by the formatter. Settings are usually displayed in the element settings dialog made available to the content manager.
Name
(Text input)
Optional
The name for this setting. The setting value can be accessed in the JSP using this name.
Alias
(Text input)
Optional
Include name
(Text input)
Optional
The include name for this setting. This can be used together with an element setting default file that contains shared setting definitions.
Displayed name
(Text input)
Optional
The name displayed in the element setting dialog for the content manager.
Description
(Text input)
Optional
The description should supply information about what this setting is used for, any which input values are allowed. The description is displayed in the element setting dialog for the content manager.
Visibility
(Select box)
Optional
Widget
(Combo box)
Optional
The widget to use to edit the setting.
Default
(Text input)
Optional
The default value.
Widget configuration
(Text input)
Optional
The widget configuration parameter(s).
Value translation
(Text input)
Optional
Validation rule
(Text input)
Optional
A regular expression used to validate the users input.
Validation type
(Select box)
Optional
Specifies if failing the regular expression test causes an error or a warning.
Error message
(Text input)
Optional
The error message to display when the validation fails.

Tab "Parameters"

Parameter
Optional - Can occur as often as necessary
Key
(Text input)
The parameter key.
Value
(Text input)
The parameter value.