[TYPO3] How to loop in TS?

Mattias Borell Mattias.Borell at med.lu.se
Tue Apr 8 13:00:33 CEST 2008


Howdy!

Dmitry Dulepov [typo3] wrote:
> Hi!
> 
> Mattias Borell wrote:
>> Maybe I did? When reading the TSref I got the impression that those two 
>> where the same (both listing UID for pages) but that pidInList had 
>> stdWrap abilities. Or does pidInList mean Parent page UID? (Am I the 
>> only one that finds TSref confusing...? :-)
> 
> uidInList uses uid field to select records using the numbers you supplied. pisInList uses pid field for the same. Normally, when you use CONTENT with tables other than "pages", you would use pidInList and give page uid there. But when you want to select from "pages" table, you have a choice: if you use pidInList, you select pages, whose parent is in the list, while uidInList will select pages, whose id values you give in list.

Ahh. That explains some of my troubles... Should have groked that 
earlier, but better later than never! :->

> For example:
> 
>> Reduced page-structure:
>> 15
>>  |-88
>>  | |-90
>>  | |-89
>>  |-87
>>  |-86
> 
> uidInList=90,89,87 will select pages with uid 90 or 89 or 87. pidInList=90,89,87 will select no pages because neither of these pages has subpages. But pidInList=88 will give you pages with uid 90 or 89.

In my case, uidInList seems to behave the way you describe pidInList 
here...?

*) pidInList ==> no values anywhere
*) uidInList ==> 90,89 when on page 88, otherwise nothing

Any ideas as to why this might be?

Typo3 4.1.5
MySQL 5.0.46
PHP 5.2.4


Regards,

/Mattias
-- 
Mattias Borell
Sysadmin // Developer
LUDC - Lund University Diabetes Centre
CRC, Entrance 72, House 60, floor 13
SE 205 02, Malmö, SWEDEN
Tel: +46 40 39 12 27


More information about the TYPO3-english mailing list