HTML <head> tag
Examples
In the head with a <title> tag of the HTML document:
<Html>
<Head>
<Meta charset = "utf-8">
<Title> Document Title </ title>
</ Head>
<Body>
Content of the document ......
</ Body>
</ Html>
try it"
(For more examples, see the bottom of the page)
Browser Support
All major browsers support the <head> tag.
Tag definitions and instructions
<Head> element is a container for all the head elements.
<Head> element must contain the title of the document (title), can contain scripts, stylesheets, meta information, and other additional information.
Elements listed below can be used inside <head> element:
Differences between HTML 4.01 and HTML5
HTML5 is no longer supported profile properties.
Attributes
属性 | 值 | 描述 |
---|---|---|
profile | URL | HTML5 不支持。规定文档 URL 的一系列规则。这些规则能被浏览器识别并且准确读取 <meta> 标签的内容属性中的信息。 |
Global Properties
<head> tag supports HTML global properties .
Try - Example
Use <base> tag in the <head>
This example demonstrates how to use the default URL <base> tag in the provision of all links page and the default target.
Using the <style> tag in the <head>
This example demonstrates how the <head> section add style information.
Use <link> tag in the <head>
This example demonstrates how to use the <link> tag to link to an external stylesheet.
related articles
HTML Tutorial: HTML head