[TYPO3] Is there something like insertData in postUserFunc?

Dmitry Dulepov [typo3] dmitry at typo3.org
Mon Sep 22 21:10:39 CEST 2008


Hi!

Joerg Wagner wrote:
> If you say "It does..." does this mean that there actually is a way to 
> use getData() to retrieve TV FCE fields? If so, could you tell me how 
> this works?

If you have FCE information inside $cObj->data, you can use getData() on it. For example, if you have in FCE:

<TypoScript>
10 = TEXT
10.data = Page uid={TSFE:id}
</TypoScript>

I do not remember how $cObj is constructed in case of FCEs. postUserFunc is called with the current object set as $cObj to the class instance. Therefore you can access object's data through $this->cObj->data and it should be usable through $this->cObj->getData(). But I am not sure why do you want to call getData() yourself?

> Yes, this is why I would be happy to use the getData method. But I 
> cannot figure out how. I tried using the second parameter, but to no avail.

Look is tslib_cObj::stdWrap():

if ($conf['data']){$content=$this->getData($conf['data'], is_array($this->alternativeData)?$this->alternativeData:$this->data);}

-- 
Dmitry Dulepov
TYPO3 Core team
My TYPO3 book: http://www.packtpub.com/typo3-extension-development/book
In the blog: http://typo3bloke.net/post-details/tag_your_typo3_extension_releases_in_svn/


More information about the TYPO3-english mailing list