[TYPO3-english] flvplayer2 and tt_news
Christopher Torgalson
bedlamhotel at gmail.com
Tue Jul 28 03:07:57 CEST 2009
Hello again,
On 27-Jul-09, at 5:32 PM, Markus Deckmann wrote:
> Hi Christopher,
>
>> Without testing it, it looks as though you've missed a small step; if
>> the 'url' object has stdWrap, you should be able to do this, but
>> stdWrap has no 'RECORDS' function which is what your TS code assumes.
>
> In the documentation it looks like 'url' have stdWrap function:
>
> http://typo3.org/documentation/document-library/extension-manuals/flvplayer2/1.2.1/view/1/4/
>
> In sourcecode from the flvplayer2 the following line in function
> "buildFlashCode" will parse the url-setting:
>
> $filePath = $this->cObj->stdWrap($this->conf['url'],$this-
> >conf['url.']);
>
> So it looks like the class parse stdWrap functions.
>
>
>> When you need to make a cObject in stdWrap, you use (surprise!) the
>> 'cObject' property, so you'll need something like
>> plugin.tx_flvplayer_pi1.url.cObject < temp.newsFileRecord.
>
> Now I am using the following TS code:
>
> ### TS code start ###
> temp.newsFileRecord = RECORDS
> temp.newsFileRecord {
> source = {GPvar:tx_ttnews|tt_news}
> source.insertData = 1
> tables = tt_news
> conf.tt_news = TEXT
> conf.tt_news.field = news_files
> #wrap = http://mydomain/fileadmin/videos/|
> wrap = |
> }
>
> plugin.tx_flvplayer_pi1 {
> width = 550
> height = 413
> playerParams.autoStart = 0
> #url = http://mydomain/fileadmin/videos/example.flv
> url = 1
> url.10 = TEXT
> url.10 {
> cObject < temp.newsFileRecord
> wrap = |
> }
> }
>
> #####################
>
> I have debug the flvplayer2-extension with a
> t3lib_div::debug($filePath), but this will return only the 1 from
> "url =
> 1" I think. Normaly it must return the "news_file"-name I have defined
> by the news-item, isnt it?
Well, you've prolonged your problem in the same way you started it: by
using a value that can ONLY be interpreted as a string and then
expecting it to be parsed as stdWrap. Remove "url = 1" (*why* is that
there in the first place? In what other TS context does a cObject
start with "foo = 1" instead of "foo = COBJECT_NAME"?), and I suspect
you'll find it suddenly works for you.
--
Christopher Torgalson
http://www.typo3apprentice.com/
More information about the TYPO3-english
mailing list