17. Why is the name attribute important in forms?
The name attribute identifies a successful form control in submitted form data. An input may have an id for DOM and label association, but without a suitable name its value generally will not be included in standard form submission.
Key Takeaways
id and name serve different purposes.
Use meaningful names for submitted form fields.
Knowledge Check
Which attribute commonly determines the field name in submitted form data?