[TYPO3-dev] BE-Module from Kickstarter and function menuConfig()

Christian Tauscher christian.tauscher at media-distillery.de
Sun Dec 27 01:33:03 CET 2009


Hi again!

In Kickstarter I have created a BE Module.

there you find this code:

function menuConfig()    {
	global $LANG;
	$this->MOD_MENU = Array (
		'function' => Array (
			'1' => $LANG->getLL('function1'),
			'2' => $LANG->getLL('function2'),
			'3' => $LANG->getLL('function3'),
			)
		);
	parent::menuConfig();
	}

Since I need a secound "Mode-menu" I have do extend $this->MOD_MENU with
the menu Entrys of my Menu.

So in my main Function I did this:

$this->MOD_MENU['myMenu'] = array( 1 => 'entry1',...);

Funny, the Menu is not rendered.
??? It is $this->....???

If I put the Menu-Definitions into the "function menuConfig()"
everything works as expected.
????

So far so good, but my Menu entrys change by a TSconfig entry and some
DB Records:
$data = t3lib_BEfunc::getModTSconfig($this->pObj->pageinfo['uid'],
'mod.'.$GLOBALS['MCONF']['name'].'.myData');
(the get the reyuired data forom DB)

But $data is never be filled with the values vom TSconfig. If I try to
fill $this->data in main-funtion, then $data is filled, but I can't
access the data in menuConfig().

I am sure this is some Class/function/Scope thing, but I have no idea
wats going on.

Maybe you can point me to the right direction,

I had a look in SYSEXT:belog, kaspar does something very similar to my
needs, he adds the BE groups to the select-menu dynamically.
Everything is a little bit different but not that much.....

OK - Kaspar is the best.


Happy New Year,

Christian.




More information about the TYPO3-dev mailing list