P
P
postgresdev2019-09-09 13:07:46
symfony
postgresdev, 2019-09-09 13:07:46

How to wrap each radio input in a separate div in Symfony?

Пример инпут:
->add('eprocurementSystemUsed', CollectionType::class, [
            'choices' => [
                1 => 1,
                2 => 2,
                3 => 3,
                4 => 4,
            ],
            'expanded' => true,
            'multiple' => false
])

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
MegaSega, 2019-10-30
@MegaSega

Same for radiobutton

{% for checkbox in form.gender.children %}
            <div class="styled-input-single">
                {{ form_widget(checkbox) }}
                {{ form_label(checkbox) }}
                {{ form_errors(checkbox) }}
            </div>
        {% endfor %}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question