[Typo3] Not render something if a menu is empty.

Ries van Twisk typo3 at rvt.dds.nl
Tue Feb 22 15:07:37 CET 2005


Peter Klein wrote:

>Hi Ries				
>
>You can test if a menu object is empty with ".if.isTrue < YourMenuObject" 
>Like in this example:
>-- cut --
>temp.tstmenu = HMENU
>temp.tstmenu {
>  entryLevel = 1
>  # Do NOT put "wrap" here!!
>  1 = TMENU
>  1 {
>    wrap = <div style="border:1px solid black">Testmenu<br>|</div>
>    NO {
>      AllWrap = |<br>
>    }
>  }
>}
>
>temp.menu = TEXT
>temp.menu.value = <br>Menu is EMPTY!!<br>
>temp.menu.if.isTrue < temp.tstmenu
>
>page.10 < temp.menu
>
>-- cut --
>
>
>- Peter Klein (pmk65)
>  
>
Peter,

thank yo for the information.
The problem is however that I want do remove something else instead of 
the menu itself
so the TS code 'temp.menu.if.isTrue < temp.tstmenu' does not work for me.

its more like:
[ifmenu empty temp.tstmenu]
    page.40 < otherthingtoshow
[end]

Currently I solved the problem with a little bit of PHP code that's 
get's called in postUserFunc

cheers,
Ries

cheers,
RIes

>-----------------------
>This thread is located in the archive at this URL:
>http://typo3.org/documentation/mailing-lists/english-main-list-archive/thread/110110815/
>					
>_______________________________________________
>Typo3-english mailing list
>Typo3-english at lists.netfielders.de
>http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
>  
>


-- 
R. van Twisk
http://www.metamorf.net

Our Typo3 enabled website: http://www.livetravelguides.com
Instand help for Typo3?    irc:/irc.freenode.net/typo3
Looking for documentation? http://typo3.org/documentation/





More information about the TYPO3-english mailing list