[TYPO3] communication between TS objects in different FCE fields
Amiran Chyb
amiran.chyb at stopspam.gmail.com
Fri Mar 3 09:03:50 CET 2006
hello
I'm designing an FCE which is going to be a teaser to a page. The page ID
to which teaser would point would be selected by user in "link" type DS
field. The problem is, I'd like to show, next to the link, number of
comments submitted on that page.
For that reason I wrote custom php function that checks this value, when
provided with pageid.
It's in a different field of this FCE, and it's TS code looks like this:
<eType>text</eType>
<TypoScript>
10 = TEXT
10.value= comments number:
20 = USER_INT
20.userFunc = user_count_comments_class->count
20.pageid = 12
</TypoScript>
the problem is that '11.pageid' field's value should be set dynamically.
Ideally, it would fetch it somehow from the LINK field of this FCE, which
would be chosen by user.
My questions:
1) how to extract id of a page chosen in LINK fce field into some TS object
2) how to set different TS object in a different field of this FCE with
this value? what about variable scope in this case?
thanks a lot
Amiran
More information about the TYPO3-english
mailing list