[TYPO3-mvc] Possibility to let Extbase-Ext return an array?
Joerg Schoppet
joerg at schoppet.de
Thu May 28 19:15:44 CEST 2009
Sebastian Kurfürst schrieb:
> Hey Jörg,
>
>> how is it possible or is it at all possible to include an action,
>> which returns an array for a menu-array with an extbase-extension?
> That does not really make sense. Actions and controllers are a special
> concept of MVC, while you just need a normal PHP class.
>
>> <example>
>> temp.menu = HMENU
>> temp.menu.special = userfunction
>> temp.menu.special.userFunc =
>> Tx_ExtExample_Controller_Category->menuAction
>> </example>
> Just use a standard PHP class which has a name like
> Tx_ExtExample_MenuGenerator and create a method named "generateMenuItems".
> The above class must reside in ext_example/Classes/MenuGenerator.php.
>
> With the above concept, you do not use the MVC framework of extbase for
> this particular problem, but that's fine (because what you want to do
> does not fit into the MVC concept).
>
> I hope this helps :-)
> Greets,
> Sebastian
Ok,
I though, I can use the automated selection of the model-classes and
also the action.link for the menu-array generation ;-)
Joerg
More information about the TYPO3-project-typo3v4mvc
mailing list