[TYPO3] How to loop in TS?
Mattias Borell
Mattias.Borell at med.lu.se
Tue Apr 8 09:24:14 CEST 2008
Hi all.
I've been given a design that calls for an html select-list where each
option has a page UID as value, and the page title between the
option-tags. As the list of UIDs changes a bit depending on where you
are in the site(s), my first thought was that split would be the right tool.
So far, I've managed to make it work with the dataWrap-like syntax so
that I can get the page titles, but I can't get the UIDs themselves...
TS-example:
temp.quickMenu-list = TEXT
temp.quickMenu-list {
value = 90,89,87
split {
token = ,
cObjNum = 1
1.current = 1
1.wrap = <option value="???">{DB:pages:|:title}</option>
}
insertData = 1
}
I can't seem to find a way to make a {DB:X:Y} that just gives the active
uid, and using a combination of standard wrap (|) and the {DB:X:Y}
doesn't seem to work either. What am I missing here? Do I need to make
this in separate steps, use another approach or...?
/Mattias, seeking TS enlightenment... :->
--
Mattias Borell
Sysadmin // Developer
LUDC - Lund University Diabetes Center
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