[TYPO3-english] Re: treatIdAsReference + images in Typo3 6.2

Matthias Eberlein skydivematy at gmail.com
Wed Feb 25 00:20:19 CET 2015


Hi Sergio,
i use this script to get images from the news extension. May you can adapt this to your need...

lib.tx_news.isotopeLandingPageImages = RECORDS
lib.tx_news.isotopeLandingPageImages {
  tables = tt_content
            conf.tt_content.stdWrap.if {
                equals.field=colPos
# list all images from column 12 Preview Images
                value=12
            }
  source.current = 1
  dontCheckPid = 1


  conf.tt_content = COA
  conf.tt_content {
    #IMAGE
    10 = FILES
    10 {
      references {
        table = tt_content
        fieldName = image
      }
      renderObj = COA
      renderObj {
        10 = IMAGE
        10 {
          wrap = |
          file {
            treatIdAsReference=1
            import.data = file:current:publicUrl
          }

          altText.data=file:current:title
          emptyTitleHandling = useAlt

          layoutKey = picturefill

            layout.picturefill {
                        element (
                        <picture class="first-match">
                        <!--[if IE 9]><video style="display: none;"><![endif]-->
                        ###SOURCECOLLECTION###

                        <!--[if IE 9]></video><![endif]-->
                        <img srcset="###SRC###" ###PARAMS### ###ALTPARAMS######SELFCLOSINGTAGSLASH###>
                        </picture>
                        )
                        source = <source srcset="###SRC###" media="###MEDIAQUERY###"/>
                        }


            sourceCollection {
	}
}

saludo
maty


More information about the TYPO3-english mailing list