user500665
user500665

Reputation: 1364

Render content elements from records field in a fluid template?

I have a custom content element that uses the records field. How can I put the records in this field into my fluid template?

I have tried doing this:

ext_example < lib.contentElement
ext_example {
    templateName = MyTemplate
    dataProcessing {
        10 = TYPO3\CMS\Frontend\DataProcessing\SplitProcessor
        10 {
          fieldName = records
          delimiter = ,
        }
    }
}

But it gives an array like this: 'tt_content_26,tt_content_30' How do I remove the prefix tt_content_ so I have a uid array that I can use?

Upvotes: 0

Views: 540

Answers (1)

Julian Hofmann
Julian Hofmann

Reputation: 2592

Per default, the records field allows only "tt_content" records. So, you have a list of UIDs of tt_content records in this field, but you're using these UIDs in the pidInList.

Upvotes: 0

Related Questions