Internal mark of HTML file head (the most refined and complete)
I. Title webpage title.
Ii. meta tag
Note: The <meta> mark must be placed between
According to HTML language standards, Meta Tags are very important for website development. They can be used to identify authors,
Set the page format, label the content feed and keywords, and refresh the page.
Meta Tags are divided into two parts: HTTP-EQUIV and name variables.
● The HTTP-EQUIV is similar to the HTTP header protocol, which responds to some useful information for the browser to help correctly and precisely display the page
.
Commonly used HTTP-EQUIV types are:
1. expires (TERM)
Note: You can set the expiration time of a webpage. Once the webpage expires, you must re-access it on the server.
Usage: <meta HTTP-EQUIV = "expires" content = "wed, 26feb
1997 08:21:57 GMT ">
Note: The GMT time format must be used.
2. Pragma (cach Mode)
Note: The browser is prohibited from reading the page content from the cache of the local machine.
Usage: <meta HTTP-EQUIV = "Pragma" content = "no-Cache">
Note: in this way, visitors will not be able to browse offline.
3. Refresh (refresh)
Note: If you need to enable the webpage to automatically link to other webpages on a regular basis, use this sentence.
Usage: <meta HTTP-EQUIV = "refresh"
Content = "5; url = http://www.yahoo.com">
Note: 5 indicates that the URL is automatically refreshed after 5 seconds.
4. Set-cookie (cookie setting)
Note: If the webpage expires, the cookie on the disk will be deleted.
Usage: <meta HTTP-EQUIV = "Set-cookie"
Content = "cookievalue = xxx;
Expires = Wednesday, 21-oct-98 16:14:21 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: <meta HTTP-EQUIV = "window-target"
Content = "_ top">
Note: It is used to prevent others from calling your page in the framework.
5. Content-Type (display character set setting)
Description: sets the character set used on the page. (We have already introduced the functions of the font design)
Usage: <meta http-equiv = "Content-Type"
Content = "text/html; charset = gb2312">
● The syntax format of the name variable of the meat tag is:
<Meta name = "XXX" content = "xxxxxxxxxxxxxxxxxx">
XXX has the following parameters:
1. Keywords)
Note: keywords are used to tell the search engine what keywords are on your webpage.
Example: <meta name = "keywords" content = "Life, universe,
Mankind, plants,
Relationships, the meaning of life, science ">
2. Description)
Description: description is used to tell the search engine the main content of your website.
Example: <meta name = "Description" content = "This pageis
About the meaning
Life, the universe, mankind and plants. ">
3. Robots (robot wizard)
Note: robots is used to tell robots which pages need to be indexed and which pages do not need to be indexed.
Content parameters include all, none, index, noindex, follow, and nofollow. The default value is all.
Example: <meta name = "Robots" content = "NONE">
4. Author (author)
Note: the author of the webpage
Example: <meta name = "author"
Content = "Ajie, ajie@netease.com">
These are some of the basic usage of meta tags, the most important of which is the setting of keywords and description.
Why? The truth is simple. These two statements allow search engines to accurately discover you and attract more people to visit your site!
According to the working principle of the popular search engine (Lycos, Altavista, etc.), the search engine first sends robots to automatically search on www.
When a new website is found, the system searches for the keywords and decription on the page and adds them to its own database.
The word density sorts websites.
That is to say:
1.
If there is no meta tag for keywords and description on your page, the robot cannot add your site to the data.
Library, it is impossible for netizens to search for your site.
2. If your keyword is poorly selected and the keyword density is not high, it may be clicked after dozens or even millions of sites.
Is also very small.
Therefore, we must remember to add the meta tags of keywords and description, and write the keywords and introduction as much as possible. Write keywords
The taboos are:
1. Do not use common words. For example, WWW, homepage, net, and Web.
2. Do not use adjectives or adverbs. For example, the best and the largest.
3. Do not use general words as accurate as possible. For example, you can switch to v998 instead of a "Motorola mobile phone ".
One of the tips for finding the right keywords is to search for websites similar to your content in Lycos, Alta, infoseek, and other search engines.
The META keywords of the top 10 websites. Copy them to your site.
Here, we will give you a keyword for the Microsoft Multimedia Website:
<Meta name = "keywords" content = "joke, music, MP3,
Media, audio, joke of the day,
Downloads, free music, horoscope, radio,
Video, music downloads, movies, radio station,
Media Player, free, download, weather, horoscopes,
Windows Media Technologies, online,
Radio station guide, free download ">
In addition, there are some tips to improve the click-through rate:
1. add keywords to the alt comment statement of the image.
For example,
2. Use HTML comments to add a large number of keywords to the page code.
Usage: <! --- Insert keywords here --->
3. Link
Displays the links between this document and other documents. One of the most useful applications is the positioning of external Cascading Style Sheets. The format is as follows:
<LINK rel = "stylesheet" href = "style.css">
The rel parameter describes the relationship between the two documents, and the href parameter specifies the target document name.
For more information about Cascading Style Sheets, see other articles.
Iv. Base
Base has two main functions:
1. <base href = "original address">
The original address of this document. In this way, the reader can know where to download your document.
2. <base target = "target framework name">
On a frame page, if you want to display the connection of a frame in another frame, for example
After the connection is displayed to the content framework, you can add <Base
Target = "content">, so there is no need
Add the target attribute to the <A> mark of all connections on the menu page, unless the connection is not displayed in the content framework.
5. bgsound mark (ie Only)
<Bgsound src = "*. mid | *. wav |..." loop = "-1">
Vi. STYLE tag
<Style type = "text/CSS">
<! --
TD {
Font-size: 12px;
Line-Height: 120%;
}
-->
</Style>
VII. Script mark
<Scriptlanguage = "JavaScript">
<! --
Alert ("welcome ")
-->
</SCRIPT>
VIII. Version Declaration
Syntax: <! -- Comment content -->
Example: <! Doctype HTML public "-// W3C // DTD html4.01
Transitional // en ">
Purpose: declare that the current document is based on HTML 4.0
IX. Notes
For example:
<! -- CSS -->
<Style type = "text/CSS">
<! --
TD {
Font-size: 12px;
Line-Height: 120%;
}
-->
</Style>
<! -- CSS end -->
Http://blog.sina.com.cn/s/blog_4ad042e50100lvqs.html