HTML <fieldset> nameAttribute
Examples
<fieldset> with a name attribute:
<fieldset name="personalia">
Name: <input type="text"><br>
Email: <input type="text"><br>
</fieldset>
Name: <input type="text"><br>
Email: <input type="text"><br>
</fieldset>
Try it Yourself »
Browser Support
![]()
![]()
![]()
![]()
![]()
All major browsers support the name attribute, except Internet Explorer.
Definition and Usage
The name attribute specifies the name of the fieldset.
The name attribute is used to reference the element in JavaScript, or to reference form data after a form is submitted.
Differences between HTML 4.01 and HTML5
This attribute is new to the <fieldset> tag in HTML5.
Syntax
<fieldset name="text">
Attribute Values
| Value | Description |
|---|---|
| name | Specifies the name of the fieldset. |
HTML <fieldset> Tag Other Extensions