HTML <! Doctype> Label

Source: Internet
Author: User

Document type DOCTYPE,Most DOCTYPE declarations trigger almost strict mode (quasi-standard), and when DOCTYPE is removed, the right to display your HTML page in the "Render mode" is completely given to the browser
" -//W3C//DTD XHTML 1.0 transitional//en "  " HTTP://WWW.W3.ORG/TR/XHTML1/DTD/XHTML1-TRANSITIONAL.DTD ">

HTML5 since it can't be deleted, then I'll simplify it.

<! DOCTYPE HTML >

It is not recommended to include any non-blank content before DOCTYPE. The HTML element is the root of all the elements in the page

"http://www.w3.org/1999/xhtml" lang="en"xml : lang="en">

xmlns attribute. It means that the elements on this page are in the XHTML namespace http://www.w3.org/1999/xhtml. However, the elements of HTML 5 have this namespace, so it is no longer necessary to specify them. Regardless of whether this attribute is available, the HTML 5 page will behave consistently across all browsers. Whereas in HTML 5 only the lang attribute is valid

"en">

The head element is the first element of the root element, and the information inside it is the information of the Web page itself, not the ontology of the Web page. (The body in the body) hidden in the head are good things, especially for seoer. metaThe role of tags is the encoding of well-known characters, and not specifying the encoding may lead to security vulnerabilities
<meta http-equiv="content-type" content="text/html; Charset=utf-8" />

HTML5 has turned it into

<meta  charset="utf-8" />

Link relationships provide a way to explain why you link to that page. Here we first come to sayrel="stylesheet"

<link rel="stylesheet" type="text/css " href= " Style.css "  />

HTML5 did a little optimization and type removed the

<link rel="stylesheet" href="style.css "  /><script src="path/to/script.js"></script>

HTML <! Doctype> Label

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.