Attention
TYPO3 v11 has reached end-of-life as of October 31th 2024 and is no longer being maintained. Use the version switcher on the top left of this page to select documentation for a supported version of TYPO3.
Need more time before upgrading? You can purchase Extended Long Term Support (ELTS) for TYPO3 v10 here: TYPO3 ELTS.
container
container
-
- Type
- array
- Path
- $GLOBALS['TCA'][$table]['ctrl']
- Scope
- Display
Array to configure additional items in render containers of FormEngine, see section Node expansion.
Next to single elements, some render container allow to be "enriched" with additional information via the "node expansion" API. Currently, the
Outer
implementsWrap Container field
andWizard field
.Information Inline
implementsControl Container field
and comes with the default wizardWizard localization
. Custom containers may implement expansion nodes, too, and if implemented correctly will automatically have their configuration merged with the definition provided in this TCA array.State Selector The basic array looks like:
'ctrl' => [ 'container' => [ '<containerRenderType>' => [ 'fieldWizard' => [ '<aName>' => [ 'renderType' => '<aRenderType>', 'before' => ['<anotherName>'], 'after' => ['<yetAnotherName>'], 'disabled' => false, 'options' => [], ], ], ], ], ],
Copied!- <containerRenderType>
-
should be a defined container render type. You can find more about the
outer
andWrap Container inline
in the FormEngine documentation section on rendering. Valid types are for example:Control Container outer
type which corresponds to theWrap Container Outer
(class).Wrap Container inline
type which corresponds to theControl Container Inline
classControl Container inline
type which corresponds to theInline
class.Control Container
- renderType
- refers to a registered node name from
Node
Factory - before, after
- can be set to sort single wizards relative to each other.
- disabled
- can be used to disable built in default wizards.
- options
- Some wizards may support additional "options".
Note, next to "fieldWizard", some containers may also implement "fieldInformation", which can be manipulated the same way.
Examples
Disable a built-in wizard
'ctrl' => [
'container' => [
'inlineControlContainer' => [
'fieldWizard' => [
'localizationStateSelector' => [
'disabled' => true,
],
],
],
],
],
This disables the default localization
fieldWizard of
inline
.
Add your own wizard
Register an own node in a ext_
:
$GLOBALS['TYPO3_CONF_VARS']['SYS']['formEngine']['nodeRegistry'][1486488059] = [
'nodeName' => 'ReferencesToThisRecordWizard',
'priority' => 40,
'class' => \T3G\AgencyPack\EditorsChoice\FormEngine\FieldWizard\ReferencesToThisRecordWizard::class,
];
Register the new node as "fieldWizard" of "tt_content" table in an Configuration/
file:
$GLOBALS['TCA']['tt_content']['ctrl']['container'] = [
'outerWrapContainer' => [
'fieldWizard' => [
'ReferencesToThisRecordWizard' => [
'renderType' => 'ReferencesToThisRecordWizard',
],
],
],
];
In PHP, the node has to implement an interface, but can return any additional HTML which is rendered in the "OuterWrapContainer" between the record title and the field body when editing a record:
Add fieldInformation to field of type inline
This example can be found in Add a custom fieldInformation.