[TYPO3-dev] Custom backend module: Link to to Web > Page Module

Patrick Rodacker patrick.rodacker at the-reflection.de
Wed Oct 8 13:01:38 CEST 2008


Hi Steffen,

Steffen Kamper schrieb:

> it's done by JS (onclick="...")
> look to top.goToModule(modName, cMR_flag, addGetVars)

ok, that pointed me in the correct direction, thanks again. The 
following code works for me:

$page = t3lib_befunc::getRecord('pages', $pid);
$url = t3lib_div::getIndpEnv('TYPO3_SITE_URL') . 
typo3/sysext/cms/layout/db_layout.php?id=' . $pid;
$link = '<a onclick="top.nextLoadModuleUrl=\'' . $url . '\'; 
top.goToModule(\'web_layout\'); return false; this.blur();" href="#">';
$link .= t3lib_div::fixed_lgd($page['title'], 25);
$link .= '</a>';

I also used the t3lib_beFunc::setUpdateSignal() function to reload the 
pagetree successfully and recognised, that I had something else in my 
mind when asking about reloading the page tree ... my fault.

What I do want to achieve is the following: expanding and reloading the 
pagetree, so the current page gets correctly highlighted and is visible 
for the user.

I had a closer look at the pagetree and found the javascript function 
Tree.load, but have problems accessing it from within the module.

The function t3lib_befunc::openPageTree() is afais not an option, 
because I am looking for a way to init the expand command in the onclick 
handler.

Regs
Patrick





More information about the TYPO3-dev mailing list