Intermediary transaction http://www.aliyun.com/zixun/aggregation/6858.html ">seo diagnose Taobao guest cloud host technology Hall
Standardized HTML code for a website has many advantages, such as: easy to adapt to the revision, code easy maintenance, small code, the site opened fast, suitable for more people to read, and so on, here are not enumerated. From the point of view of website optimization, the standardized HTML code is more used in search engine rankings. But a lot of stationmaster did not realize this point, influence website in search engine rank.
Below, we begin to make initial improvements to our website:
Add DOCTYPE to a Web page
What is DOCTYPE? DOCTYPE is the shorthand for document type, understand what is DOCTYPE! DOCTYPE is a document type that describes your HTML or XHTML version, and the browser interprets the page code based on the DTD (document type definition) defined in your DOCTYPE, and you can imagine, What happens to the wrong doctype.
XHTML1.0 provides us with three kinds of doctype:
1. Transition type (Transitional)
<! DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 transitional//en" "Http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd ">
2. Strict type (Strict)
<! DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 strict//en" "Http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd" >
3. Frame type (SET)
<! DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 set//en" "Http://www.w3.org/TR/xhtml1/DTD/xhtml1-set.dtd" >
Transition-compatible forms, logos, etc., for beginners, choose the transition type on it!
Set a name space
Add the following code after DOCTYPE:
<html xmlns= "http://www.w3.org/1999/xhtml" >
xmlns is a shorthand for XHTML namespace, called "namespaces," and usually our web page has only <html> why is there xmlns? A namespace is a sign of a document that describes who the document specification belongs to. Do you understand? Pass without understanding.
Declarative language encoding
The Simplified Chinese website can be defined as:
< http-equiv= "Content-type" content= "HTML; charset=gb2312 "/>
English website can be defined as:
< http-equiv= "Content-type" content= "HTML; Charset=utf-8 "/>
Other settings between <Head></Head>
1. Favorites Small Icon
Make a 16*16 ico icon, name it favicon.ico, place it in the root directory of your site, and then place the following code between <Head></Head>.
<link rel= "icon" href= "/favicon.ico" type= "Image/x-icon"/>
<link rel= "disambiguator icon" href= "/favicon.ico" type= "Image/x-icon"/>
2. Author and copyright information
< Name= "Author" content= "Hxstream"/>
< name= "Copyright" content= "www.firefoxba.com, All rights reserved"/>
3. Site Introduction
< Name= "Deion" content= "seo168 for the vast number of enterprises to provide SEO optimization services"/>
4. Site Keywords
< content= "Search engine optimization, seo" name= "keywords"/>
Close all labels
Open tags must be closed, such as <p>www.firefoxba.com</p>, and of course there is a way to close, such as:<br/>
Attribute values are enclosed in ""
For example: <img height= "....../>"
Assign values to all properties
Incorrect wording: <input ... checked/>
The correct wording is: <input ... checked= "checked"/>
All XHTML elements and their attribute names in lowercase
XHTML is case sensitive
The wrong wording is:<title>www.firefoxba.com</title>
The standard is written as:<title>www.firefoxba.com</title>
Label should be properly nested
Incorrect wording:<div><h1>www.firefoxba.com</div></h1>
The correct wording is:<div><h1>www.firefoxba.com</h1></div>
Special characters with coded IDs
such as "<" with "<" Said, ">" with ">" Said。
Add alt attribute to picture
The Alt property specifies that the text is displayed for replacement when the picture cannot be displayed.
such as: <img src= "/images/logo.gif" alt= "seo168 to serve You"/>
Output content with structured elements
For example: you want to enter three lines of text, you can use:
Www.firefoxba.com<br/>www.firefoxba.com<br/>www.firefoxba.com
I suggest replacing the above by the following way:
<ul>
<li>www.firefoxba.com</li>
<li>www.firefoxba.com</li>
<li>www.firefoxba.com</li>
</ul>
These specifications can make a primary improvement to your site, improve the search engine on your site rating. Look at this dororo of things, the mind is not Meng, drink a cup of tea, the luck!