0

I am not able to align radiobutton list to left of label above. Here is code

  <div style="border-radius: 10px;">
        <div style="margin-bottom: 10px"></div>
        <asp:Panel ID="panel" runat="server">
            <div style="padding-left: 10px" >
                <asp:Label ID="lbl" runat="server" Text="Select criteria" />
                <asp:RadioButtonList ID="radio" runat="server" AutoPostBack="True" OnSelectedIndexChanged="radio_SelectedIndexChanged" RepeatDirection="Horizontal"   />
                <asp:Label ID="lbl1" runat="server" Text="Value"></asp:Label>
                <br />
                <asp:TextBox ID="txt" runat="server"></asp:TextBox>
                <asp:Label ID="ScoreMethodLabel" runat="server" Text="Score"></asp:Label>
                <asp:DropDownList ID="dropscore" runat="server" />&nbsp;
            </div>

        </asp:Panel>
        <br/>
    </div>

Here is output i see

enter image description here

you see the option button is not aligned exaxctly below text called "Select criteria"

James
  • 1,827
  • 5
  • 39
  • 69
  • right click the radio button, *inspect element* (on chrome atleast) and hover over the element in the inspector panel - then check if the element shows any orange / purple coloring, if this is true orange means margin and purple means padding. You can then go ahead and reset that in your CSS – SidOfc Jan 06 '16 at 11:22
  • @SidneyLiebrand i see Orange color but even if i added margin its not aligning – James Jan 06 '16 at 11:27
  • @SidneyLiebrand when i open up html using F12. Then its rendered as input type=radio and when i add margin:0 then it Works. But not when i directly add property margin:0 on asp:radiobuttonlist – James Jan 06 '16 at 11:47
  • Here is a similar question on so http://stackoverflow.com/questions/7767812/radio-button-text-on-the-right-side – शेखर Jan 06 '16 at 12:10
  • @शेखर thats not what i want. I want to align option button to left of label above. – James Jan 06 '16 at 12:27

1 Answers1

0

try to margin:0

* {
   margin: 0;
   }

input[type=radio] {
        margin: 0;
   }
Lalji Tadhani
  • 14,041
  • 3
  • 23
  • 40