Friday, 15 June 2012

typo3 - fallback for FILES in typoscript -



typo3 - fallback for FILES in typoscript -

i'm using typoscript go first file out of page. works , out of documentation. documentation doesn't tell fallback if no files found.

lib.files = files lib.files { references { table = pages fieldname = media } file = begin = 0 maxitems = 1 renderobj = text renderobj { value = url: {file:current:publicurl} insertdata = 1 } }

a naive .if.isnull failed @ first attpent. there possibilty define fallback if files-object empty?

mh,

try create sec object , check there if lib.files filled data.

__

untested lib.files = files lib.files { references { table = pages fieldname = media } file = begin = 0 maxitems = 1 renderobj = text renderobj { value = url: {file:current:publicurl} insertdata = 1 } } lib.filefallback = coa lib.filefallback { 10 < lib.files 20 = text 20 { value = stdwrap.if.isfalse.cobject < lib.filefallback.10 } }

i using technique slide through pages slideshow objects.

let me know, if working.

typo3 typoscript

No comments:

Post a Comment