[TYPO3-dev] Backend: Where to put new main menu used by several extensions?

Kay Strobach typo3 at kay-strobach.de
Fri Jul 29 09:40:52 CEST 2011


Hi,

you can declare one of you extensions as base extension.

This one can be easily added as requirement to the others.
In the Mainextension you can add you module ;)

Regards
Kay

Am 29.07.2011 08:27, schrieb Christian Weiske:
> Hi,
> 
> 
> Some of your extensions provide backend module and shall get grouped in
> their own main module.
> 
> Adding modules into a main category is easy with using
>> t3lib_extMgm::addModule('company', "txcompanymod', ...);
> - if the main category has been created already. If it is not there
> yet, it gets the same title as the module.
> 
> So to have our custom main category title, we need to add it before the
> normal module is added:
>> if (!isset($TBE_MODULES['company'])) {
>>     t3lib_extMgm::addModule(
>>         'company', '', 'after:web',
>>         t3lib_extMgm::extPath($_EXTKEY) . 'mod_main/'
>>     );
>> }
> (btw, after:web for main modules works with the patch from
>  http://forge.typo3.org/issues/28502
> )
> 
> 
> Now my question:
> 
> Where should we put the creation of the main company module? In every
> single extension that wants to add itself as submodule?
> 
> That's a pretty bunch of duplicated code that I'd rather have at one
> centralized place.
> 
> 


-- 
http://www.kay-strobach.de - Open Source Rocks

TYPO3 .... inspiring people to share!
Get involved: http://typo3.org




More information about the TYPO3-dev mailing list