Use of META tags

Source: Internet
Author: User

Metadata (Metadata) is the data information of the data.
The <meta> tag provides metadata for the HTML document. The metadata is not displayed on the client, but is parsed by the browser.
1, define the document keywords, for the search engine:
<meta name= "keywords" content= "html,css,xml,xhtml,javascript" >
2, define the Web page description:
<meta name= "description" content= "Free web tutorials on HTML and CSS" >
3. Define the page
<meta name= "Author" content= "Cacti" >
4. Refresh the page every 30 seconds:
<meta http-equiv= "Refresh" content= ">"
5, 360 browser meta tag use--Use the fast mode (ie WebKit kernel)
If the page needs to be the default speed core, add tag: <meta name= "renderer" content= "WebKit" >
If the page needs to default IE compatible kernel, add tag: <meta name= "renderer" content= "Ie-comp" >
If the page needs to default with IE standard kernel, add tag: <meta name= "renderer" content= "Ie-stand" >
6. Meta tag control IE rendering standard mode and compatibility mode
<meta http-equiv= "x-ua-compatible" content= "Ie=edge" >
<meta http-equiv= "x-ua-compatible" content= "Ie=7,ie=9"/>
<meta http-equiv= "x-ua-compatible" content= "Ie=emulateie7,ie=emulateie9"/>
<meta http-equiv= "x-ua-compatible" content= "ie=7,9"/>
Document mode is a new concept introduced by IE8. The document mode of the page determines which level of CSS you can use, which APIs you can use for JavaScript, and how to treat document types (DOCTYPE).
From the above example, you can see that the value of "x-ua-compatible" has two ways: the Emulate+ie version number, the simple version number. What is the difference between the two?
Edge: Always render pages in the most recent document mode. Ignores document type declarations. For IE8, pages are always rendered in IE8 Standard mode. IE9 is also true.
EMULATEIE9: If the document type is declared, the page is rendered in IE9 Standard mode, otherwise the document mode is set to IE5. EMULATEIE8: If the document type is declared, the page is rendered in IE8 Standard mode, otherwise the document mode is set to IE5. EMULATEIE7: If the document type is declared, the page is rendered in IE7 Standard mode, otherwise the document mode is set to IE5.
9: Forces the page to render in IE9 Standard mode, ignoring document type declarations.
8: Forces the page to render in IE8 Standard mode, ignoring document type declarations.
7: Forces the page to render in IE7 Standard mode, ignoring document type declarations.
5: Forces the page to render in IE5 Standard mode, ignoring document type declarations.

Perhaps you in the actual use of x-ua-compatible, may appear not to work, in fact, can not just add: meta, but also need to remove the definition of DOCTYPE, in fact, this can be: <! DOCTYPE html>. Check to see if you have this in your code: <! DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 transitional//en" "Http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd > try to get rid of it.

Use of META tags

Related Article

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.