[TYPO3] TS override with userFunc

Xavier Perseguers typo3 at perseguers.ch
Sun Aug 24 10:59:53 CEST 2008


Hello,

>> I know from TSRef there is a possiblity of handling some complex 
>> conditions using "[userFunc = user_mycondition(param)]" syntax. So I 
>> can have my own PHP function where i can do all the complex work to 
>> decide the TRUE or FALSE. But what I would like to do is to manipulate 
>> an object from TS setup with this function.
>>
>> e.g. what i need is as follows:
>>
>> lib.myObj = TEXT
>> lib.myObj.value = Test me
>>
>> [userFunc = user_mycondition(param)]
>> #somehow the lib.myObj should be overridden here.
>> [end]
>>
>> #here i get new value of lib.myObj
>>   
> 
> More precisely, I have n number of lib objects stored in a TEXT field in 
> one of my custom table. So I would like to parse those strings to TS 
> using t3lib_TSparser and then push parsed setup array into the 
> TSFE->tmpl somehow so that those objects will be available for rendering 
> i.e. should be available to templavoila further.
> 
>> Will it be possible with userFunc or any other idea using some hooks?

I do not understand exactly what you try to achieve but I would say that 
you should use a USER (or USER_INT) object instead of TEXT.

If you think you need more help, I think that an example a bit less 
generic would be wise.

-- 
Xavier Perseguers
http://xavier.perseguers.ch/en


More information about the TYPO3-english mailing list