Zum Inhalt springen

Wrap options and hierarchy in menus

A menu normally consists of more than just the individual links. At least everything should be displayed as a list. However, in order to realize certain designs, additional HTML tags are sometimes necessary. Here we list the options available and the order in which they are displayed:

#start first menu level
wrapItemAndSub
  allStdWrap
     allWrap
       beforeWrap
         before
      beforeWrap
           stdWrap2
             linkWrap
               stdWrap
                 Menu item first level, active, not linked
               stdWrap
             linkWrap
           stdWrap2
         afterWrap
       after
         afterWrap
     allWrap
  allStdWrap
#this is where the second level starts
wrapItemAndSub
   allStdWrap
     allWrap
       beforeWrap
         before
       beforeWrap
           stdWrap2
             linkWrap
               <a>
                 stdWrap
                   Menu item second level, linked
                 stdWrap
               </a>
             linkWrap
           stdWrap2
         afterWrap
       after
         afterWrap
     allWrap
  allStdWrap 
wrapItemAndSub
#end second level
wrapItemAndSub
#end first level

If you enter ATagBeforeWrap = 1 in the TypoScript, linkWrap is also output within the a tag:

...
<a>
linkWrap
stdWrap
Menu item second level, linked
stdWrap
linkWrap
</a>
...

 

Listing of the TypoScript hierarchy of stdWrap:

outerWrap
wrap3
prepend
dataWrap
wrap2
noTrimWrap
wrap
preCObject
innerWrap2
innerWrap
Textual content
innerWrap
innerWrap2
postCObject
wrap
noTrimWrap
wrap2
dataWrap
append
wrap3
outerWrap
Updated: 09.04.2025