Remove dividing "," from the select field property rendering

Hey
All selections should end up in a string to be classes: e.g. class=" selection1 selection2 ".
But by default they are divided by ","

Is there a sexy way to remove the commas?

I tried:

<?= $file->position()->split(",") ?>

But that gives only an array and of course I need a string…

<?= implode(' ', $file->position()->split(',')) ?>

https://www.php.net/manual/de/function.implode.php

1 Like

uuh. I didn’t know this. great!
So no Kirby method needed for this.

Thanks a lot !