[TYPO3] menu - how to count and display included subpages?
Peter Klein
peter at umloud.dk
Wed Jan 4 11:06:32 CET 2006
Hi rene. it's close.. Take a look at this stand-alone example..
-- cut --
lib.test = COA
lib.test {
# Save the output of numRows in the registervalue: "menuNumber"
10 = LOAD_REGISTER
10.menuNumber.numRows {
table = pages
select.pidInList.data = field:uid
}
# Retrieve the registervalue and display it.
20 = TEXT
20.dataWrap = <div>There are {register:menuNumber} subpages to the page:
{field:title}</div>
}
page.30 < lib.test
-- cut --
--
Peter Klein/Umloud Untd
"rene" <gnome2k at web.de> skrev i en meddelelse
news:mailman.1.1136323015.18779.typo3-english at lists.netfielders.de...
> Peter Klein wrote:
>> Hi rene. You could either create a COA which can contain several TEXT (or
>> other) objects, or use LOAD:REGISTER to store the value of .numRows, and
>> then use dataWrap to wrap it all up..
>>
> hello peter.
>
> could you please give me an example? currently i don't have any ideas
> how i could do this neither with a COA or LOAD_REGISTER.
>
> i tried the following but then stopped cause of no idea how to go on:
>
> 10 = TEXT
> 10.numRows {
> table = pages
> select.pidInList.data = field:uid
> }
>
> 20 = LOAD_REGISTER
> 20.myMenuCounter < .10
>
> i think that's really erroneous isn't it?
>
> thanks in advance.
More information about the TYPO3-english
mailing list