---
title: "Problem bei Action-Auswahl per FlexForm"
url: "https://www.typo3.net/d/108805-problem-bei-action-auswahl-per-flexform"
source: "typo3.net"
tags: ["Extensions","Extbase","FlexForms","Frage"]
created: "2012-01-02"
last_reply: "2012-01-03"
replies: 1
solved: false
page: 1
pages: 1
lang: "de"
---

# Problem bei Action-Auswahl per FlexForm

Extensions › Extbase · 1 Antwort · gestartet 2012-01-02

## Eröffnungsbeitrag

**9pm** · 2012-01-02 · [Beitrag #1](https://www.typo3.net/d/108805-problem-bei-action-auswahl-per-flexform/1)

Hallo zusammen!

Ich habe eine Extension mit einem PlugIn erstellt, bei welchem man die Möglichkeit hat verschiedene Ansichten auszuwählen (FlexForm). Für jede Ansicht ist eine entsprechende Action hinterlegt. Allerdings wird immer nur die erste Action aufgerufen, die in der **ext_localconf.php** definiert ist. Diese sieht so aus:

```php
<?php
if (!defined('TYPO3_MODE')) {
	die ('Access denied.');
}

Tx_Extbase_Utility_Extension::configurePlugin(
	$_EXTKEY,
	'Liexteditorial',
	array('EditorialContent' => 'listslider, listteaser, listhorizontal, listvertical, show',),

	// non-cacheable actions
	array('EditorialContent' => '',)
);
```

... in meiner **ext_tables.php** steht folgendes:

```php
Tx_Extbase_Utility_Extension::registerPlugin(
	$_EXTKEY,
	'Liexteditorial',
	'Editorial Content'
);

$pluginSignature = str_replace('_','',$_EXTKEY) . '_' . liexteditorial;
$TCA['tt_content']['types']['list']['subtypes_addlist'][$pluginSignature] = 'pi_flexform';
t3lib_extMgm::addPiFlexFormValue($pluginSignature, 'FILE:EXT:' . $_EXTKEY . '/Configuration/FlexForms/flexform_' .liexteditorial. '.xml');
```

... und meine FlexForm beinhaltet folgende Selectbox:

```php
<switchablecontrolleractions>
    <TCEforms>
        <label>LLL:EXT:li_ext_editorial/Resources/Private/Language/locallang_db.xml:flexform_label_controllerAction</label>
        <config>
            <type>select</type>
            <items type="array">
                <numIndex index="0">
                    <numIndex index="0">Slider</numIndex>
                    <numIndex index="1">EditorialContent->listslider</numIndex>
                </numIndex>
                <numIndex index="1">
                    <numIndex index="0">Teaser</numIndex>
                    <numIndex index="1">EditorialContent->listteaser</numIndex>
                </numIndex>
                <numIndex index="2">
                    <numIndex index="0">Horizontal-Ansicht</numIndex>
                    <numIndex index="1">EditorialContent->listhorizontal</numIndex>
                </numIndex>
                <numIndex index="3">
                    <numIndex index="0">Vertikal-Ansicht</numIndex>
                    <numIndex index="1">EditorialContent->listvertical</numIndex>
                </numIndex>
                <numIndex index="4">
                    <numIndex index="0">Detailansicht</numIndex>
                    <numIndex index="1">EditorialContent->show</numIndex>
                </numIndex>
            </items>
            <maxitems>1</maxitems>
            <size>1</size>
        </config>
    </TCEforms>
</switchablecontrolleractions>
```

Kann mir bitte jemand weiter helfen und sagen woran das liegt?
Sehe ich den Wald vor lauter Bäumen nicht mehr?? :(

Viele Grüße

## Antworten

### [#2](https://www.typo3.net/d/108805-problem-bei-action-auswahl-per-flexform/2) · 9pm · 2012-01-03

Guten Morgen!

Nach langem experimentieren habe ich herausgefunden dass es daran lag dass "switchablecontrolleractions" komplett klein geschrieben war. Es muss aber folgendermaßen aussehen "<switchableControllerActions>" (ohne Anführungszeichen natürlich). Nun klappt es ...

Viele Grüße

---

Quelle: „Problem bei Action-Auswahl per FlexForm“, typo3.net, https://www.typo3.net/d/108805-problem-bei-action-auswahl-per-flexform
Beiträge von Mitgliedern des Forums. Bitte mit Link auf die Diskussion zitieren.
