HTML <head> Tag
The <head> tag in HTML is used to define the head portion of the document which contains information related to the document.
The <head> tag contains other head elements such as <title>, <meta>, <link>, <style> <link> etc.
In HTML 4.01 the <head> element was mandatory but in HTML5, the <head> element can be omitted.
Tag Specific Attributes:
The below-mentioned layout-attributes of the <hr> tag have been removed from HTML5.
- profile: It is used to specify the URL to a document that contains one or more metadata profiles for browsers to clearly understand the information.
<head> <title>Title of the document</title> </head>
Below program illustrates the <head> element:
Program 2(Using style tag inside head tag)
Program 3(Using link tag inside head tag):
- Google Chrome
- Internet Explorer
Attention reader! Don’t stop learning now. Get hold of all the important Comcompetitivepetitve Programming concepts with the Web Design for Beginners | HTML course.