Search code examples
typo3typo3-extensions

How do I use dce:explode() in typo3?


sorry, but I don't know which other Tags to use for this question.

I'm using typo3 with dce extension. I want to use dce:explode to separate values from a comma separated string:

{field.category -> dce:explode(delimiter:',')}

field.category contains "value1,value2,value3"

But this gives always an error in the frontend: Oops, an error occurred! Code: 2015082814003052e1ee30

Can anyone help?


Solution

  • I solved it. I'm just a typo3 noob and simply forgot to define the dce namespace before using it:

    {namespace dce=ArminVieweg\Dce\ViewHelpers}
    

    Now it works fine