About http-equiv and httpequiv
Http-equiv, as its name implies, is equivalent to an http File Header. It can return some useful information to the browser to help display the webpage content correctly and accurately. The corresponding attribute value is content, content is actually the variable value of each parameter.
The syntax format of the http-equiv attribute that references the meat tag is: <meta http-equiv = "parameter" content = "parameter variable value">; the http-equiv attribute has the following parameters:
1. Expires (TERM)
Note: You can set the expiration time of a webpage. Once the webpage expires, it must be re-transmitted to the server.
Usage: Html code
- <Meta http-equiv = "expires" content = "Wed, 20 Jun 2007 22:33:00 GMT">
Note: The GMT time format must be used.
2. Pragma (cache Mode)
Note: It is used to disable the browser from accessing the page content from the Cache on the local machine. Once set, the page cannot be called out from the Cache once it leaves the web page.
Usage: Html code
- <Meta http-equiv = "Pragma" content = "no-cache">
Note: in this way, visitors will not be able to browse offline.
3. Refresh)
Note: automatically refresh and point to the new page.
Usage: Html code
- <Meta http-equiv = "Refresh" content = "2; URL = http://www.net.cn/">
Note: 2 means that the URL is automatically refreshed after 2 seconds.
4. Set-Cookie (cookie setting)
Note: If the webpage expires, the cookie on the disk will be deleted.
Usage: Html code
- <Meta http-equiv = "Set-Cookie" content = "cookievalue = xxx; expires = Wednesday, 20-Jun-2007 22:33:00 GMT; path =/">
Note: The GMT time format must be used.
5. Window-target (display Window settings)
Note: The Force page is displayed on an independent page in the current window.
Usage: Html code
- <Meta http-equiv = "Window-target" content = "_ top">
Note: It is used to prevent others from calling their own pages in the framework.
6. content-Type (display character set setting)
Description: sets the character set used on the page.
Usage: Html code
- <Meta http-equiv = "content-Type" content = "text/html; charset = gb2312">
7. Pics-label (webpage rating)
Usage: Html code
- <Meta http-equiv = "Pics-label" contect = "">
Note: There is a content setting in the internet option of IE, which can prevent browsing of some restricted websites. The restricted level of websites is set through the meta attribute.
8. Page_Enter and Page_Exit
Set the special effect Html code when entering the page
- <Meta http-equiv = "Page-Enter" contect = "revealTrans (duration = 1.0, transtion = 12)">
Set the special effect Html code when leaving the page
- <Meta http-equiv = "Page-Exit" contect = "revealTrans (duration= 1.0, transtion = 12)">
The Duration value is the dynamic transition time of the webpage, in seconds.
Transition is a transitional mode. Its value ranges from 0 to 23, corresponding to 24 Transition modes respectively. See the following table:
0-box contraction 1-box radiation
2 circular contraction 3 circular radiation
4 From bottom up 5 from top down
6 from left to right 7 from right to left
8 vertical blinds 9 horizontal blinds
10 horizontal blinds 11 vertical blinds
12 dissolve at will 13 expand from left and right ends to the middle
14 expand from the center to the left and right sides 15 expand from the up and down ends to the middle
16. expand from the middle to the bottom. 17. expand from the top right to the bottom left.
18 expand from bottom right to top left 19 from top left to bottom right
20. Expand the 21 horizontal lines from the lower left corner to the upper right corner.
22 vertical linear expansion 23 random generation of a transitional mode
9. Clear the cache (access this website again and download it again !)
Html code
- <Meta http-equiv = "cache-control" content = "no-cache">
10. Set the webpage expiration time
Html code
- <Meta http-equiv = "expires" content = "0">
11. keywords for search engines
Html code
- <Meta http-equiv = "keywords" content = "keyword1, keyword2, keyword3">
12. Page Description
Html code
- <Meta http-equiv = "description" content = "This is my page">