Website title name"; 2. h1, h2, h3, h4, h5, h6 elements, which can be defined The titles in the document content are of decreasing importance from h1 to h6."/> Website title name"; 2. h1, h2, h3, h4, h5, h6 elements, which can be defined The titles in the document content are of decreasing importance from h1 to h6.">

Home >Web Front-end >Front-end Q&A >What elements do html5 use for titles?

What elements do html5 use for titles?

青灯夜游
青灯夜游Original
2022-01-11 16:15:333329browse

html5 elements used to make titles: 1. title element, which can define the title of the document, with the syntax "

Website title name"; 2. h1, h2, h3, h4 , h5, h6 elements can define the title in the document content, and the importance is decreasing from h1 to h6.

What elements do html5 use for titles?

The operating environment of this tutorial: Windows 7 system, HTML5 version, Dell G3 computer.

html5 Title elements

1. Use the title element--the title of the website document

# The ## tag defines the title of the document and is required in all HTML documents. <p></p> <title> Element: <p></p> <ul style="list-style-type: disc;"> <li> Defines the title in the browser toolbar <p></p> </li> <li> Provides the page to be added to the collection The title when clipped <p></p> </li> <li>The page title that appears in search engine results<p></p> </li><pre class="brush:html;toolbar:false"><!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>php中文网</title> </head> <body> ... </body> </html></pre></ul> <p><img src="https://img.php.cn/upload/image/464/449/197/1641888737445495.png" title="1641888737445495.png" alt="What elements do html5 use for titles?"></p> <p> 2. Use the </p> <h1> to <h6> tag - the title of the document content <strong></strong> In order to make the web page more semantic, title tags are often used in the page. HTML provides 6 There are three levels of headings, namely <h1>, <h2>, <h3>, <h4>, <h5> and <h6>, with decreasing importance from <h1> to <h6>. </h6> </h1> </h6> </h5> </h4> </h3> </h2> </h1> </h6> </h1> <p><pre class="brush:html;toolbar:false"><!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>php中文网</title> </head> <body> <h1>这是标题 1</h1> <h2>这是标题 2</h2> <h3>这是标题 3</h3> <h4>这是标题 4</h4> <h5>这是标题 5</h5> <h6>这是标题 6</h6> </body> </html></pre></p> <p><img src="https://img.php.cn/upload/image/927/935/964/1641888824845456.png" title="1641888824845456.png" alt="What elements do html5 use for titles?"></p>Related recommendations: "<p>html video tutorial<a href="http://www.php.cn/course/list/11.html" target="_blank" textvalue="html视频教程">"</a></p>

The above is the detailed content of What elements do html5 use for titles?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Previous article:What is page in html5Next article:What is page in html5