1,看一下头部

先看一下xhtml的写法

<!DOCTYPEhtmlPUBLIC"-//W3C//DTDXHTML1.0Strict//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><htmlxmlns="http://www.w3.org/1999/xhtml"><head><title>title</title><metaname="description"content="description"/><linkrel="stylesheet"type="text/css"href="/c3.css"/><metahttp-equiv="Content-Type"content="text/html;charset=gb2312"/><metahttp-equiv="Content-Language"content="zh-cn"/><metaname="robots"content="all"/><metaname="author"content="lunanzuche.com.cn"/><metaname="Copyright"content="Copyrightwww.lunanzuche.com AllRightsReserved."/><metaname="MSSmartTagsPreventParsing"content="true"/><metahttp-equiv="p_w_picpathtoolbar"content="false"/>

看一下html5

<!DOCTYPEhtml><htmllang="en-US"><head><metacharset="utf-8"/><metaHTTP-EQUIV="Content-Type"CONTENT="text/html;charset=utf-8"><title>GoldmanSachs</title>

显著区别在于:

<metacharset="utf-8"/>

<!DOCTYPEhtmlPUBLIC"-//W3C//DTDXHTML1.0Strict//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><htmlxmlns="http://www.w3.org/1999/xhtml">

<!DOCTYPEhtml><htmllang="en-US">
当然 lang可以不写

<metahttp-equiv="Content-Type"content="text/html;charset=gb2312"/>
换成了: