HTML HTML Forms Choosing Options Radio Buttons

Nicholas Wallen
Nicholas Wallen
10,402 Points

So "id" is associated with something else, like the label, whereas "name" is associated with something on backend?

So "id" is associated with something else, like the label, whereas "name" is associated with something on backend?

1 Answer

The name attribute is used when sending data in a form submission. Different controls respond differently. For example, you may have several radio buttons with different id attributes, but the same name. When submitted, there is just the one value in the response - the radio button you selected.

Of course, there's more to it than that, but it will definitely get you thinking in the right direction. Hope that helps