<input type="radio" name="group1" />1
<input type="radio" name="group1" />2
How do i know witch one is selected when the form is posted ?
<input type="radio" name="group1" />1
<input type="radio" name="group1" />2
How do i know witch one is selected when the form is posted ?
The inputs should have values:
<input type="radio" name="group1" value="1" />1
<input type="radio" name="group1" value="2" />2
Then, the value will be posted on the name group1
. On Asp.net you can get it using:
Request.Form["group1"]
If you are using runat="server", it can happen that name attribute is changed at client, so you will get null as value.