I have a Symfony Form and I try to display a SelectField
with different Icons.
My ChoiceType looks like this
->add('icon', ChoiceType::class, [
'choices' => [
'' => '',
'' => '',
],
'mapped' => false,
])
My CSS looks like this
select { font-family: 'FontAwesome', Verdana }
When I render a normal select div it works very well and i can see the icons.
But when try it via the Symfony Form it does not work. I have already read other Threads with the same problem. One solution was the to set the auto-escape of twig to false and try to work with the raw tag. But still i just see the pure text "" and not the Icons in the Select Box.