<LEGEND>
A legend is used to provide a caption to a FIELDSET element. A FIELDSET
groups a related set of input controls and content together for easier navigation.
This is especially useful for non-graphical user agents (browsers) to expain the usage
of the input controls.
Attributes
Attribute |
Description |
ID |
Identifies this tag to reference in script (program code) |
CLASS |
Define the class used to render this element (defined by a style sheet) |
TITLE |
A title that is associated with the element (displayed as a tooltip in Internet Explorer) |
ALIGN |
[DEPRECATED] Indicates the horizontal alignment of text for the caption. This is replaced by the CSS specification. |
|
Example
<FORM action="testlengend.php" method="post">
<FIELDSET>
<LEGEND>Personal Information</LEGEND>
Last Name: <INPUT NAME="lastname" TYPE="text" TABINDEX="1"><br>
First Name: <INPUT NAME="firstname" TYPE="text" TABINDEX="2"><br>
Address: <INPUT NAME="address" TYPE="text" TABINDEX="3"><br>
...more personal info...
</FIELDSET>
</FORM>
Renders As:
Compatibility
HTML 4.01
|