Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8964981
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T16:42:42+00:00 2026-06-15T16:42:42+00:00

Default radio widget creates a following structure: <label>…</label> <div id=…> <div class=clearfix prettyradio labelright

  • 0

Default radio widget creates a following structure:

<label>...</label>
<div id="...">
<div class="clearfix prettyradio labelright  blue">
<input type="radio" id="..._0" name="..." value="..." style="display: none;">
<a href="#" class=""></a>
...
</div>

I found the radio_widget block, but it contains only an input itself. So I can customize there only this part:

<input type="radio" id="..._0" name="..." value="1" style="display: none;">

But I can’t understand how to change whole the structure of radio choice field?

Also, does anybody knows, why symfony adds display:none to the input?

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T16:42:43+00:00Added an answer on June 15, 2026 at 4:42 pm

    if you’re using Radio Field Type, you can customize only the input part of the radio_widget block by calling form_widget(form.yourField), all it displays is,

    {% block radio_widget %}
    {% spaceless %}
        <input type="radio" {{ block('widget_attributes') }}{% if value is defined %} value="{{ value }}"{% endif %}{% if checked %} checked="checked"{% endif %} />
    {% endspaceless %}
    {% endblock radio_widget %}
    

    But if you’re using Choice Field Type to display Radio Fields (expanded => true and multiple => false). You’ll then have to override the choice_widget block, which call for each child element the radio_widget block surrounded by a global div

    How did you get the “display:none”? because there’s no style such this in the default block.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following radio buttons, none of which is checked by default. <input
The default decorator for the Zend_Form_Element_Radio is <label for=type_id-1><input type=radio name=type_id id=type_id-1 value=1>Pack</label> The
Use default: <input type=radio name=restype value=resdef onfocus=document.getElementById('resupload').disabled = true; document.getElementById('resadres').disabled = true; checked=checked /><br
I'm styling my input[type=radio]'s with CSS, because I need to replace the default radio
By default, there are 5 bands that android provide in its Equalizer class. I
I have 2 radio buttons no one of them checked by default and I
I created a dynamic radio group. By default it is like this: (o) XX
I have a form with some radio buttons that are disabled by default. When
I have a group of radio buttons with one of them checked by default:
I have radio buttons in HTML like this: <td> <input id=radio1 type=radio name=correctAnswer value=1>1</input>

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.