TYPO3 CMS  TYPO3_6-2
TYPO3\CMS\Form\Layout Class Reference
Inheritance diagram for TYPO3\CMS\Form\Layout:
TYPO3\CMS\Core\SingletonInterface tx_form_System_Layout

Public Member Functions

 __construct (array $layout=array())
 
 getLayoutByObject ($elementName, $layoutDefault, $layoutOverride='')
 
 setLayout (array $layout=array())
 
 setLayoutByElement ($elementName, $layout)
 

Protected Attributes

 $layout = array()
 

Detailed Description

This file is part of the TYPO3 CMS project.

It is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, either version 2 of the License, or any later version.

For the full copyright and license information, please read the LICENSE.txt file that was distributed with this source code.

The TYPO3 project - inspiring people to share! Layout class for the form elements

Author
Patrick Broens patri.nosp@m.ck@p.nosp@m.atric.nosp@m.kbro.nosp@m.ens.n.nosp@m.l

Definition at line 22 of file Layout.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Form\Layout::__construct ( array  $layout = array())

Constructor

Parameters
$layoutarray Layout array from form configuration

Definition at line 36 of file Layout.php.

References TYPO3\CMS\Form\Layout\$layout, and TYPO3\CMS\Form\Layout\setLayout().

Member Function Documentation

◆ getLayoutByObject()

TYPO3\CMS\Form\Layout::getLayoutByObject (   $elementName,
  $layoutDefault,
  $layoutOverride = '' 
)

Get the layout of the object Looks if there is an assigned layout by configuration of the element otherwise it will look if there is a layout set in the form configuration If both values are not assigned, take the default one

Parameters
string$elementNameType of object
string$layoutDefaultThe default layout of the object
string$layoutOverrideAssigned layout to this object
Returns
string The new layout if changed

Definition at line 51 of file Layout.php.

References TYPO3\CMS\Form\Layout\$layout.

◆ setLayout()

TYPO3\CMS\Form\Layout::setLayout ( array  $layout = array())

Overrides the default layout configuration for one or more elements

Parameters
array$layoutThe layout array
Returns

Definition at line 68 of file Layout.php.

References TYPO3\CMS\Form\Layout\$layout.

Referenced by TYPO3\CMS\Form\Layout\__construct().

◆ setLayoutByElement()

TYPO3\CMS\Form\Layout::setLayoutByElement (   $elementName,
  $layout 
)

Overrides the default layout configuration for one element identified by the element name

Parameters
string$elementNameType of object
string$layoutXML containing layout for element
Returns

Definition at line 83 of file Layout.php.

References TYPO3\CMS\Form\Layout\$layout.

Member Data Documentation

◆ $layout