Search results

Name and Value in form submit

The name attribute of the RadioButton is used to group RadioButton. When the RadioButton are grouped in form, the checked items value attribute will be post to server on form submit that can be retrieved through the name. The disabled RadioButton value will not be sent to the server on form submit.

In the following code snippet, Credit and Debit card is in checked state. Now, the value that is in checked state will be sent on form submit.

@Html.EJS().RadioButton("radio1").Label("Credit/Debit Card").Name("payment").Checked(true).Render()
@Html.EJS().RadioButton("radio2").Label("Net Banking").Name("payment").Render()
@Html.EJS().RadioButton("radio3").Label("Cash on Delivery").Name("payment").Render()


.e-radio-wrapper {
  margin-top: 18px;

button {
  margin: 20px 0 0 5px;

li {
  list-style: none;

public ActionResult Form()
    return View();