[TYPO3] how to get Page Number using TS?

David Lanier mailinglists at davidlanier.com
Wed Jan 24 00:59:24 CET 2007


this is actually very close to what I need.

I did get this to work as a TMENU, like you have it here.  But I could 
not get {register:count_HMENU_MENUOBJ} to show to be replaced properly 
in a GMENU.  Here are a few things that I've tried:

page.77 = HMENU
page.77 {
  1 = GMENU
  1 {
    NO = 1
    NO {
      ATagParams = someAttrib="{register:count_HMENU_MENUOBJ}"
      insertData = 1
    }
  }
}

NO is also configured for colors and text.  It's rendering properly.  
But the data isn't getting inserted.

Other ways that I have tried configuring NO are:

NO.stdWrap.dataWrap = menu item number: {register:count_HMENU_MENUOBJ}

or

NO.allWrap = <li someAttrib="{register:count_HMENU_MENUOBJ}">|</li>
NO.allWrap.insertData = 1

This method almost works.  The problem is that it inserts the TOTAL 
number of pages, instead of the current page number.

Thanks for all your suggestions!
-david

>
> page.77 = HMENU
> page.77 {   
>     1 = TMENU
>     1 {
>         noBlur = 1
>         expAll = 1
>         wrap = <ul>|</ul>
>        
>         NO = 1
>         NO {
>             wrapItemAndSub = |</li>
>             stdWrap.dataWrap = <li> [page id: {field:uid}][menu item 
> number:
> {register:count_HMENU_MENUOBJ}] |
>         }
>     }
>     
>     2 < .1
>     3 < .1
>     4 < .1
> }
>


More information about the TYPO3-english mailing list