In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-01 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article introduces the relevant knowledge of "what is the role of meta in html". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!
The role of meta tags in html: 1, search engine optimization (SEO); 2, define page usage code; 3, automatically refresh and point to new pages; 4, realize the dynamic effect of page conversion; 5, control page buffering; 6, page rating evaluation; 7, control the window of web page display, etc.
The operating environment of this tutorial: windows7 system, HTML5 version, Dell G3 computer.
Meta summary of html
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.
The meta tag serves the following purposes:
1. Search engine optimization (SEO)
two。 Define page usage coding
3. Automatically refresh and point to a new page
4. Realize the dynamic effect of web page conversion
5. Control page buffering
6. Web page rating and evaluation
7. The window that controls the display of the web page
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:
The specific parameters are 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
D, author (author)
Description: label the author of the web page
For example:
E 、 generator
The information parameter of the generator of the meta tag, which indicates what software is used to make the website.
F 、 COPYRIGHT
The information parameter of the COPYRIGHT of the meta tag, which represents the copyright information of the website.
G 、 revisit-afte
Revisit-after represents website revisit, 7days represents 7 days, and so on.
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:
The details are as follows:
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.
G, content-Language (setting of display language)
Usage:
H, http-equiv= "imagetoolbar"
Specify whether to display the picture toolbar, when false represents not to display, when true represents display.
J 、 Content-Script-Type
The W3C web page specification indicates the type of script in the page.
L page jump, for IE only
This is the end of the content of "what is the function of meta in html". Thank you for your reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!
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.