[TYPO3] Split menu with variable number of items in half

John Kavanagh john.kavanagh at roomthree.com
Mon Jun 18 21:02:51 CEST 2007


 

Hello,

 

Does anybody know if it is possible to add an active state to the links
of the menu generated in this code?

 
 
-- cut --
lib.splitmenu = COA
lib.splitmenu {
 
  10 = HMENU
  10.special = directory
  10.special.value = 1
  10.1 = TMENU
  10.1 {
    wrap = <div>1st half of menu items<br>|</div>
    NO {
      stdWrap.cObject = COA
      stdWrap.cObject {
        10 = TEXT
        10.field = title
        if.value.data = register:count_HMENU_MENUOBJ
        if.negate = 1
        if.isLessThan.prioriCalc=1
        if.isLessThan.cObject=TEXT
        if.isLessThan.cObject.insertData=1
        if.isLessThan.cObject.value = ({register:count_menuItems}+1)/2
        wrap = |<br>
      }
    }
  }
  20 < .10
  20.1.wrap = <div>2nd half of menu items<br>|</div>
  20.1.NO.stdWrap.cObject.if.negate >
}
 
page.200 < lib.splitmenu
-- cut --

 

I tried ACT = 1 but that just duplicated the active link on the other
opposite side of the menu.

I also tried to duplicate the code for the normal state for the active
but it had the same problem.

 

Any help would be greatly appreciated!!

 

Thanks,

 

John

 

 

Roomthree Design
29-30 Dame Street 
Dublin 2 
Phone +353 1 6709019 
Fax +353 1 6709215 
www.roomthree.com <http://www.roomthree.com/>  


The information in this e-mail is confidential and may be legally
privileged. 
It is intended solely for the addressee. Access to this e-mail by anyone
else 
is unauthorised. If you are not the intended recipient, any disclosure,
copying, 
distribution, or any action taken or omitted to be taken in reliance on
it, 
is prohibited and may be unlawful

 



More information about the TYPO3-english mailing list