<legend> tag in HTML
The <legend> tag used to defines a caption for the <fieldset> element.
- Open and close tag required of <legend>.
Example of <legend> tag
Result Look Like
<legend> Tag Browser Support
All modern and old browser supports <legend> tag, the list of browsers mentioned below:
Element |
Chrome |
Edge |
Firefox |
Safari |
Opera |
<legend> |
Yes |
Yes |
Yes |
Yes |
Yes |
Global Attributes
Event Attributes
Attributes
Align attribute is not supported in HTML5:
Attribute |
Value |
Description |
align |
top
bottom
left
right |
Defines the alignment of the caption |