Felix
Felix

Reputation: 5629

TYPO3 TypoScript active rootNode in Webseite in Menu

I've got a TYPO3 page (6.2.31) and want to make the root node actvie in typoscript. roodnode is the globe.

my typoscript looks like this at the moment:

NAVIMAIN = HMENU
NAVIMAIN.entryLevel = 0
#NAVIMAIN.excludeUidList = 

NAVIMAIN {
    1 = TMENU
    1 {
        expAll = 1
        wrap = <ul class="sf-menu">|</ul>
        noBlur = 1

        NO = 1
        NO.ATagTitle.field = title
        NO.wrapItemAndSub = <li>|</li>  

        ACT = 1
        ACT.wrapItemAndSub = <li class="active"> |</li>  

    }

    2 = TMENU
    2 {
        expAll = 1
        maxItems = 10
        wrap = <div class="sf-mega">|</div>
        NO = 1
        NO {
          ATagTitle.field = title
          wrapItemAndSub = <div class="sf-mega-section">|</div>
          stdWrap.wrap = |
          ATagParams =  class="headermega"
          stdWrap.htmlSpecialChars = 1
          doNotLinkIt = 0
        }
    }

    3 = TMENU
    3 {
        expAll = 1
        maxItems = 20
        wrap = <ul>|</ul>
        NO = 1
        NO {
          ATagTitle.field = title
          linkWrap = <li>|</li>
        }
        ACT = 1
        ACT {
          wrapItemAndSub = <li>|</li>
          ATagParams =  class="active"
        }
    }
    #4 < .3

   }

All other pages are marked as aktive. only the rood node not.

enter image description here

root node is the globe, there is one link (third) that redirects to root node

Whats my problem? Thanks

Upvotes: 0

Views: 169

Answers (1)

Thomas L&#246;ffler
Thomas L&#246;ffler

Reputation: 6174

I suppose you want the menu item (which links to your root node) stated as active. With the TypoScript option alwaysActivePIDlist and a condition you can do that.

Example:

[globalVar = TSFE:id = <page uid of root node>]
    NAVIMAIN.alwaysActivePIDlist = <page uid you want to set as active>
[global]

Upvotes: 1

Related Questions