- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to include a title in a fieldset in HTML?
Use the <legend> tag to include a title. The HTML <legend> tag s used to define a title for <fieldset> tag. It supports the following attribute −
Attribute | Value | Description |
---|---|---|
Align | top bottom left right | Deprecated − Specifies the content alignment. |
Example
You can try to run the following code to implement <legend> tag in HTML −
<!DOCTYPE html> <html> <head> <title>HTML legend Tag</title> </head> <body> <form> <fieldset> <legend>Student Details</legend> Student Name: <input type = "text"><br /> MBA Subjects:<input type = "text"><br /> </fieldset> </form> </body> </html>
Advertisements