In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
Editor to share with you what is the use of the http-equiv attribute in the meta tag, I believe most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!
Meta is an auxiliary tag in the head area of the html language. Maybe you think this code is optional. In fact, if you can use meta tags, it will bring you unexpected results, the functions of meta tags are: search engine optimization (SEO), define the page language, automatically refresh and point to the new page, achieve the dynamic effect of page conversion, control page buffering, page rating evaluation, control the page display window, and so on!
The composition of meta tag: meta tag has two attributes, they are http-equiv attribute and name attribute, different attributes have different parameter values, these different parameter values achieve different web page functions.
1. Name attribute
The name attribute is mainly used to describe web pages, and the corresponding attribute value is the content in content,content, which is mainly convenient for search engine robots to find information and classification information.
The name attribute syntax format of the meta tag is:
.
The name attribute mainly has the following parameters:
A, Keywords (keyword)
Description: keywords is used to tell search engines what keywords are on your web page.
For example:
B, description (website content description)
Description: description is used to tell search engines the main content of your site.
For example:
C, robots (Robot Wizard)
Description: robots is used to tell search robots which pages need to be indexed and which do not.
The parameter to content is all,none,index,noindex,follow,nofollow. The default is all.
For example:
D, author (author)
Description: label the author of the web page
For example:
2. Http-equiv attribute
Http-equiv, as the name implies, is equivalent to the header function of http. It can send back some useful information to the browser to help display the content of the web page correctly and accurately. The corresponding attribute value is the content in content,content is actually the variable value of each parameter.
The http-equiv attribute syntax format of the meta tag is:
The http-equiv attribute mainly has the following parameters:
A, Expires (term)
Description: can be used to set the expiration time of a web page. Once the web page expires, it must be retransmitted to the server.
Usage:
Note: the time format of GMT must be used.
B, Pragma (cache mode)
Description: prevent browsers from accessing page content from the cache on the local computer.
Usage:
Note: with this setting, visitors will not be able to browse offline.
C, Refresh (Refresh)
Description: automatically refresh and point to the new page.
Usage: (pay attention to the quotation marks after the number of seconds and after the URL respectively)
Note: 2 of them refers to the automatic refresh to the URL URL after staying for 2 seconds.
D, Set-Cookie (cookie setting)
Note: if the web page expires, then the saved cookie will be deleted.
Usage:
Note: the time format of GMT must be used.
E, Window-target (setting of display window)
Description: forces the page to be displayed as a separate page in the current window.
Usage:
Note: used to prevent others from calling their own pages in the frame.
F, content-Type (display character set settings)
Description: sets the character set used by the page.
Usage:
G, content-Language (setting of display language)
Usage:
H and Cache-Control specify the caching mechanism that requests and responses follow.
Cache-Control specifies the caching mechanism that requests and responses follow. Setting Cache-Control in a request message or response message does not modify the caching process during another message processing. Cache instructions at the time of request include no-cache, no-store, max-age, max-stale, min-fresh, on
Ly-if-cached, the instructions in the response message include public, private, no-cache, no-store, no-transform, must-revalidate, proxy-revalidate, max-age. The instructions in each message are as follows
Public indicates that the response can be cached by any cache
Private indicates that all or part of a response message for a single user cannot be processed by a shared cache. This allows the server to describe only part of the response message of the user, which is not valid for requests from other users
No-cache indicates that request or response messages cannot be cached
No-store is used to prevent important information from being inadvertently published. Sending in a request message causes both the request and response messages to be cached.
Max-age instructs the client to receive responses with a lifetime of no more than a specified time (in seconds)
Min-fresh indicates that the client can receive a response whose response time is less than the current time plus a specified time.
Max-stale instructs the client to receive response messages that exceed the timeout period. If you specify the value of the max-stale message, the client can receive a response message that exceeds the specified value of the timeout period.
Tips for using Meta tags:
Meta tag is a language used to describe the attributes of web pages. Standard Meta tags can facilitate the ranking of search engines and improve the weight ranking of search engines. If you want the website to be more in line with the search engine standards, you must understand the meta tag. Here is the reason for Seoer to talk about the meaning and usage of the meta tag:
1. Keywords of META tag
It is written as:
The information parameter of the Keywords of the meat tag indicates what the keyword of the site is.
2. Description of META tag
The information parameter of the Description of the meta tag represents the main content of the website and what the overview is.
3. Http-equiv=Content-Typecontent= "text/html of META tag
Http-equiv=Content-Type represents the header protocol of HTTP, which prompts the information of the browser's web page.
When the information parameter of the charset of the meta tag, such as GB2312, indicates that the code used on the website is simplified Chinese.
When the information parameter of the charset of the meta tag, such as BIG5, indicates that the coding used on the website is in traditional Chinese
When the information parameter of the charset of the meta tag, such as iso-2022-jp, indicates that the coding used by the website is in Japanese.
The information parameter of the charset of the meta tag, such as ks_c_ 5601, indicates that the code used on the website is Korean.
The information parameter of the charset of the meta tag, such as ISO-8859-1, indicates that the code used on the website is in English.
The information parameter of the charset of the meta tag, such as UTF- 8, represents the universal language coding.
4. Generator of META tag
The information parameter of the generator of the meta tag, which indicates what software is used to make the website.
5. Author of META tag
The information parameter of the author of the meta tag, which represents the copyright author information of the web page.
6. Http-equiv= "Refresh" of META tag
The Refresh of the meta tag represents how long the page is automatically refreshed, plus the URL parameter in Url represents how long it takes to automatically link to other URLs.
7. HTTP-EQUIV= "Pragma" CONTENT= "no-cache" of the META tag
It means that browsers are not allowed to access the page content from the local computer's cache, so that visitors will not be able to browse offline.
8. COPYRIGHT of META tag
The information parameter of the COPYRIGHT of the meta tag, which represents the copyright information of the website.
9. Http-equiv= "imagetoolbar" of the META tag
Specify whether to display the picture toolbar, when false represents not to display, when true represents display.
10. Content-Script-Type of META tag
The W3C web page specification indicates the type of script in the page.
11. Revisit-after of META tag
Revisit-after represents website revisit, 7days represents 7 days, and so on.
12. Robots of META tag
Robots representative tells search engine robot which pages to crawl.
The attributes are described as follows:
The information parameter is all: the file will be retrieved and the links on the page can be queried
The information parameter is none: the file will not be retrieved and the links on the page cannot be queried
The information parameter is index: the file will be retrieved
The information parameter is follow: links on the page can be queried
The information parameter is noindex: the file will not be retrieved, but the links on the page can be queried
The information parameter is nofollow: the file will be retrieved, but the links on the page cannot be queried
The above is all the content of the article "what is the use of the http-equiv attribute in the meta tag". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.