JSP in <meta http-equiv= "pragma" content= "No-cache" > Properties ttp-equiv Function Introduction < reprint >

Source: Internet
Author: User
Tags set time sorts

http-equiv, as the name implies, is equivalent to the HTTP file header function, it can send back some useful information to the browser to help correct and accurate display of the content of the Web page, and the corresponding property value of content,content content is actually the variable value of each parameter. Meat tags for httpThe-equiv property syntax format is: <meta http-equiv= "parameter" content= "parameter variable value", where http-The Equiv property mainly has the following parameters: A, Expires (term) Description: can be used to set the expiration time of the page.     Once the page expires, it must be retransmitted to the server. Usage: 
    -equiv= "Expires" content= "Fri, Jan 2001 18:18:18 GMT"> Note: The time format of GMT must be used.     B, Pragma (cache mode) Description: Prevents the browser from accessing the page content from the local computer's cache. Usage: 
    -equiv= "Pragma" content= "No-cache"> > Note: This setting makes it impossible for visitors to browse offline.     C, Refresh Description: Automatically refreshes and points to the new page. Usage: 
    -equiv= "Refresh" content= "2;url=http://www.webjx.com"> > Note: 2 of these are automatically refreshed to URL URLs after 2 seconds of stay. D, Set-Cookie (cookie setting) Description: If the page expires, the cookie will be deleted. Usage: 
    -equiv= "Set-cookie" content= "COOKIEVALUE=XXX; Expires=friday, 12-jan-2001 18:18:18 GMT; path=/"> Note: The time format of GMT must be used. E, Window-Target (display window setting) Description: Forces the page to appear on a separate page in the current window. Usage: 
    -equiv= "Window-target" content= "_top"> Note: Used to prevent others from calling their own pages in the frame. F. Content-Type (setting of the display character set) Description: Sets the character set used by the page. Usage: 
    -equiv= "Content-type" content= "text/html; charset=gb2312 "the function of meta tags we've covered some of the basic components of META tags, and then we'll take a look at the common features of META tags:1, help homepage by the major search engine login meta tag of a very important function is to set the keyword, to help your home page by the major search engine login, increase the number of site visits. In this function, the most important thing is to set the keywords and description. Because according to the search engine work principle, the search engine first sends out the robot automatically retrieves the keywords and the decription in the page, and joins it to own database, then sorts the website according to the keyword density. Therefore, we must set up keywords to improve the search clickthrough rate of the page. Let's give an example for your reference: 
    = "keywords" content= "Web page, Web page creation, Web site effects, build station guide, tutorial download, animation production, Web teaching, web material, video tutorials, technical forum, free space, free domain">
    = "description" content= "Web teaching Web site of professional web teaching website"When these keywords are set, the search engine automatically adds these keywords to the database and sorts them according to the density of the keywords. 2, define the language of the page this is the most common feature of the META tag, we will see it in pure HTML code when making a Web page, it is to define the language of your Web page, when visitors visit your Web page, the browser will automatically recognize and set the language in the page, if you set a GB code page , and the browser does not install the GB code, then the Web page will only render browsers default language set by the viewer. Similarly, if the page is English, then charset=en. The following is a representative example: 
    -equiv=″content-type″content=″text/html; charset=gb2312″〉 This code means that the language of the Web page is set to the GB code. 3, automatically refreshes and points to the new page if you want to make your Web page unattended, you can automatically refresh the page by using the META tag to access the specified page within the specified time. Let's take a look at some code: 〈meta http-equiv=″refresh″content=″2; Url=http://www.webjx.com″〉This code allows the current page to automatically go to HTTP after 2 seconds://www.webjx.com page, this is the role of Meta Refresh, in content, 2 represents the set time (in seconds), and the URL is automatically connected after a specified time page address. 4, to achieve the animation effect of Web page conversion using META tags, we can also enter the Web page or the moment we leave the page to animate, we just in the HTML code of the page   /Add the following code between the head> Tags: 
    -equiv= "Page-enter" content= "Revealtrans (duration=5.0, transition=20)">
    -equiv= "Page-exit" content= "Revealtrans (duration=5.0, transition=20)"> Once the above code is added to a webpage, we will see some special effects when we go in and out of the page , which is actually the same as the format in FrontPage2000/page transition, but we should note that the added page can not be a frame page; 5, Web site rating IE4.0 The browsers above can prevent browsing some restricted websites, and the browser will automatically identify certain sites that are restricted because the site's level has been set in the META tag of the site, and that rating is RSAC by the United States, That is, the Entertainment Commission rating agency assesses if you need to evaluate your website, you can connect to the website http://www.rsac.org/, submit the form as required, then RSAC will provide you with a meta code to copy to your page. Here is a sample code:〈meta http-equiv=″pics-label″content=′ (pics-1.1″http://Www.rsac.org/ratingsv01.html″L GentrueComment″rsaci North America Server″ for″http://Www.rsac.org″on″2001.08.16t08:15-0500″r (n0 S 0 v 0 L 0)) ′〉6, control the page buffer meta tag to set the time that the page expires, that is, when you set up the browser in Internet Explorer to view the page in the local buffer first, then when you browse a Web page, and local buffering is sometimes, The browser will then automatically browse through the pages in the buffer until the time set in the meta expires, and the browser will then get to the new page.  For example, the following code indicates that the expiry time of the Web page is January 12, 2001 18:18 18 seconds. 〈meta http-equiv=″expires″content=″friday, 12-jan-2001 18:18:18gmt″〉7, control the page display window we can also use META tags to control the page Display window, as long as the page to add the following code: 
    -equiv= "Window-target" content= "_top", this code prevents the page from being called by someone else as a frame.

Article Source: (Original address)http://blog.sina.com.cn/s/blog_5428279c01000a89.html

JSP in <meta http-equiv= "pragma" content= "No-cache" > Properties ttp-equiv Function Introduction < reprint >

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.