Flexform 

\nn\t3::Flexform() 

Load and parse FlexForms

Overview of Methods 

\nn\t3::Flexform()->getFalMedia($ttContentUid = NULL, $field = ''); 

Deletes FAL media that were specified directly in the FlexForm

\nn\t3::Flexform()->getFalMedia( 'falmedia' );
\nn\t3::Flexform()->getFalMedia( 'settings.falmedia' );
\nn\t3::Flexform()->getFalMedia( 1201, 'falmedia' );
Copied!
$cObjData = \nn\t3::Tsfe()->cObjData();
$falMedia = \nn\t3::Flexform()->getFalMedia( $cObjData['uid'], 'falmedia' );
Copied!

| @return array

| ➜ Go to source code of Flexform::getFalMedia()

\nn\t3::Flexform()->getFlexform($ttContentUid = NULL); 

Retrieves the flexform of a specific content element as an array

\nn\t3::Flexform()->getFlexform( 1201 );
Copied!

| @return array

| ➜ Go to source code of Flexform::getFlexform()

\nn\t3::Flexform()->insertCountries($config, $a = NULL); 

Inserts options from TypoScript for selection in a FlexForm or TCA.

	
select

nn\t3\Flexform->insertCountries
1
	
Copied!

| @return array

| ➜ Go to source code of Flexform::insertCountries()

\nn\t3::Flexform()->insertOptions($config, $a = NULL); 

Inserts options from TypoScript for selection in a FlexForm or TCA.

	
select

nn\t3\Flexform->insertOptions
plugin.tx_extname.settings.templates

tx_extname.colors

value
1
Nothing

1
	
Copied!

Various types of structure are permitted for the Typoscript:

plugin.tx_extname.settings.templates {
    # Direct key => label pairs
    small = Small Design
    # ... or: Label set in subarray
    mid {
        label = Mid Design
    }
    # ... or: Key set in subarray, practical e.g. for CSS classes
    10 {
        label = Big Design
        classes = big big-thing
    }
    # ... or a userFunc. Returns one of the variants above as an array
    30 {
        userFunc = nn\t3\Flexform->getOptions
    }
}
Copied!

The selection can be restricted to certain controller actions in the TypoScript. In this example, the "Yellow" option is only displayed if the switchableControllerAction | Category->list has been selected.

plugin.tx_extname.settings.templates {
    yellow {
        label = Yellow
        controllerAction = Category->list,...
    }
}
Copied!

| @return array

| ➜ Go to source code of Flexform::insertOptions()

\nn\t3::Flexform()->parse($xml = ''); 

Converts a Flexform XML into an array

\nn\t3::Flexform()->parse('');
Copied!

Also exists as a ViewHelper:

{rawXmlString->nnt3:parse.flexForm()->f:debug()}
Copied!

| @return array

| ➜ Go to source code of Flexform::parse()

Methods