[TYPO3] How to overwrite HMENU?

Johannes Konert johanneskonert at gmx.de
Wed Jul 19 08:01:41 CEST 2006

Hi Bing,

> The HMENU of page1 is like the following in the main template.

> temp.nav.10 = HMENU
> temp.nav.10 {

I suggest using entryLevel for the HMENU as well
  temp.nav.10.entryLevel = 1 (or whatever)

> The following is the extension template I created for page2 in the hope 
> to erase temp.nav and reconstruct it to show the menu starting from 
> page2.  But the menu on page2 is still the same as that on page1.

I think that is, because first the template of page1 is processed. There 
you use the temp.nav (which is still the old one) somewhere like
page = PAGE
page.20 < temp.nav

or whatever.
Afterwards the subtemplate is processed,
temp.nav is changed but never again used.
Maybe it helps to set some page.xx < temp.nav in your subtemplate again, 
but I am not very experienced with the templates cause I am mainly 
developer and not user.

> temp.nav >  # get rid of the original content of temp.nav
> temp.nav = COA
> temp.nav.stdWrap.dataWrap = <div id="nav">|</div>
> temp.nav.10 = HMENU
> temp.nav.10.special = list
> temp.nav.10.special.value = 3117  # 3117 is page2's id.

Why don't you use special = directory ? This will create a menu of all 
subpages of the given uids. In your code you get only one menu-element.
..or even use the same menu like on the main-page, just set entryLevel 
to a new value.


More information about the TYPO3-english mailing list