Skip to content Skip to sidebar Skip to footer

How Can I Add Multiple Radio Checked In One Column

I want multiple radio checkboxes. In one line it should be private or shared and in the second line, it should be with ATV or Without ATV so people on my web can select shared and

Solution 1:

this is how it looks private and shared are up and down not in one lineThe name tags on your ATV checkboxes should be changed from "occupancy" to something else like "atv". You could also wrap each group of inputs in separate divs if you want them to appear in separate rows. Finally you should also make your ids unique and update you label for tags so:

<divclass="container style1"style="padding-left: 0;padding-top: 5px;"><divclass=""><inputtype="radio"name="occupancy"id="private"checked="checked"><labelfor="private">Private</label><inputtype="radio"name="occupancy"id="shared"><labelfor="shared">Shared</label></div><div><inputtype="radio"name="atv"id="withatv"checked="checked"><labelfor="withatv">With ATV</label><inputtype="radio"name="atv"id="withoutatv"><labelfor="withoutatv">Without ATV</label></div></div>

I added a style1 class to your container but maybe you might want to add that style directly to .container. Anyway add these styles:

.style1{
flex-direction:column;
}
label[for="private"], label[for="shared"] { {
display: inline-block;
}

Post a Comment for "How Can I Add Multiple Radio Checked In One Column"