[TYPO3] Another TypoScript problem/question

bernd wilke xoonsji02 at sneakemail.com
Tue Apr 22 14:17:23 CEST 2008


on Tue, 22 Apr 2008 10:43:05 +0200, Stephen Bungert wrote:

> I have a GMENU with all the pages in a directroy. When one of the menu
> items is clicked on, the menu should change. To show a link to the home
> page (I've done this), and a link to the current page (with link
> disabled). It's reuired tob e a GMENU for visual consistency (the
> designer used shadows and things).
> 
> So I want to try and make a GMENU of the current Page only.
> 
> This is what I have
> 
> temp.nsnBar1 = HMENU
> 
> temp.nsnBar1.special = directory
> temp.nsnBar1.special.value = 153
> temp.nsnBar1.maxItems = 1
> 
> temp.nsnBar1.1 = GMENU
> 
> temp.nsnBar1.1 {
>   
>   wrap = <table class="nsnBarButtons" {$tbAtts}><tbody>|</tbody></table>
>   useLargestItemX = 1
>   useLargestItemY = 1
>   
>   NO {
>     
>     wrap = <tr><td height="{$tdHei}" width="{$tdWid}">|</td></tr> XY =
>     220,30
>     format = gif
>     backColor = #FFD57A
>     maxWidth = 220
>     ATagTitle.field = subtitle // title
>     
>     4 = IMAGE
>     4.file = fileadmin/templates/nsnportal/images/nsn_fade_large_bg.gif
>     4.tile = 3,1
>     
>     10 = SHADOW
>     10.offset = 1,1
>     10.color = #ffffff
>     10.textObjNum = 20
>     
>     20 = TEXT
>     20.text.field = subtitle // title
>     20.offset = 5,20
>     20.align = left
>     20.niceText = 1
>     20.fontColor = #662D91
>     20.fontSize = 10
>   }
>   NO.noLink = 1
> }

have you read about ACT and CUR beside NO? (Chapter 10.2 in TSRef)

in this way you can assign different configuration for pages in the 
actual path (ACT) or only the current page (CUR) 

example1: http://lists.netfielders.de/pipermail/typo3-english/2005-
August/011620.html

example2:
temp.nsnBar1.1 {
    :
    NO  {
        :
        backColor = #FFD57A
        :
    }
    // copy configuration and change only the needed:
    ACT = 1
    ACT < .NO
    ACT {
        :
        backColor = #7AD5FF
        :
    }
    // copy configuration and change only the needed:
    CUR = 1
    CUR < .NO
    CUR {
        :
        backColor = #D5FF7A
        :
    }
}

 
bernd
-- 
http://www.pi-phi.de/t3v4/cheatsheet.html


More information about the TYPO3-english mailing list