HTML 标签

HTML 4.01 specifies three document types: Strict, Transitional, and Frameset.
在HTML4.01中有三种文档类型:严密型,过渡型以及框架型。
HTML Strict DTD
Use this when you want clean markup, free of presentational clutter. Use this together with Cascading Style Sheets (CSS):
当你想要用比较整洁的标记,从混乱的观念里解脱的话可以选择严密型的DTD。结合CSS使用:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
HTML Transitional DTD
The Transitional DTD includes presentation attributes and elements that W3C expects to move to a style sheet. Use this when you need to use HTML's presentational features because your readers don't have browsers that support Cascading Style Sheets (CSS):
过渡型DTD包含一些W3C预计会移向样式表中的属性和元素。如果你感觉读者的浏览器不一定会支持CSS的话可以选择这个类型的文档
(目前流行的浏览器都支持CSS,只是大部分CSS2属性还不行)
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
Frameset DTD
The Frameset DTD should be used for documents with frames. The Frameset DTD is equal to the Transitional DTD except for the frameset element replaces the body element:
框架型DTD应该配合带有框架的文档使用。框架DTD基本等同于过渡型除了frameset元素替代了body元素
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
XHTML
XHTML 1.0 specifies three XML document types: Strict, Transitional, and Frameset.
指定了三种XML文档类型:严密型,过渡型,以及框架型
XHTML Strict DTD
Use this DTD when you want clean markup, free of presentational clutter. Use this together with Cascading Style Sheets (CSS):
当你想要用比较整洁的标记,从混乱的观念里解脱的话可以选择严密型的DTD。结合CSS使用:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
XHTML Transitional DTD
Use this DTD when you need to use XHTML's presentational features because your readers don't have browsers that support Cascading Style Sheets (CSS):
如果你感觉读者的浏览器不一定会支持CSS的话可以选择这个类型的文档,它可以使用一些不被推荐的标签和属性:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
XHTML Frameset DTD
Use this DTD when you want to use frames!
如果你想用到框架请用这个。
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
To check that you have written a valid XHTML document with a correct DTD,  you can link your XHTML page to an XHTML validator.
要检查你的页面是否符合DTD的要求,可以用将你的页面连接到相应的校验器上。

你可能感兴趣的:(html,框架,css,XHTML,浏览器)