DIV CSS 佈局教程網

您现在的位置: DIV+CSS佈局教程網 >> 網頁腳本 >  >> HTML基礎知識 >> HTML和Xhtml
IE6 網頁製作參考:IE6 預設樣式表
編輯:HTML和Xhtml     

這並非IE官方文件,而是他人透過實踐整理出的IE6預設樣式。它對我們「馴服」IE6很有參考價值,能幫助你從根本理解IE那些bug的成因。可惜IE不像Firefox那樣能透過網址列指令直接查看預設樣式。

=======================================
INTERNET EXPLORER 6 DEFAULT STYLE SHEET
=======================================
****** HYPOTHETICAL *******************
This is a work in progress.
Values are purely indicative.

/* Standard HTML elements
These values may be affected by the
hasLayout property. */

/* Block-level elements */
html, body,
div, p,
blockquote,
ul, ol, dl,
dt, dd, address,
form, fieldset,
frame, frameset,
h1, h2, h3, h4,
h5, h6, hr, pre {display: block;}
head {display: none;}
html {margin: 0;}
body {margin: 8px;}
div {margin: 0;}
p {margin: 1em 0;}
blockquote {margin: 1em 40px;}
ul {margin: 1em 0 1em 40px; list-style-type: disc;}
li {display: list-item;}
ol {margin: 1em 0 1em 40px; list-style-type: decimal;}
ul ul {margin: 0 0 0 40px; list-style-type: circle;}
ul ul ul {margin: 0 0 0 40px; list-style-type: square;}
dl {margin: 1em 0;}
dd {margin-left: 40px;}
address {margin: 1em 0; font-style: italic;}
form, fieldset {margin: 0;}
fieldset {border: 1px inset <sistem color>;}
h1, h2, h3, h4, h5, h6 {font-weight: bold;}
h1 {font-size: 2em; margin: .6em 0;}
h2 {font-size: 1.5em; margin: .8em 0;}
h3 {font-size: 1.1em; margin: 1em 0; }
h4 {font-size: 1em; margin: 1.3em 0;}
h5 {font-size: 0.8em; margin: 1.6em 0;}
h6 {font-size: 0.6em; margin: 2.3em 0;}
hr {border: 2px outset <sistem color>;}
pre {margin: 1em 0; font-family: monospace; white-space: pre;}

/* Inline elements */
a, i, cite, em, var, acronym,
tt, code, kdb, samp, del, ins,
u, dfn, sub, sup, big, small {display: inline; }
a:link {color: blue; text-decoration: underline; }
a:visited {color: purple; text-decoration: underline;}
i, cite, em, var {font-style: italic;}
tt, code, kbd, samp {font-family: monospace;}
del {text-decoration: line-through;}
u, ins {text-decoration: underline;}
sub {
vertical-align: sub;
font-size: smaller;
line-height: <value>;
}
sup {
vertical-align: super;
font-size: smaller;
line-height: <value>;
}
big {font-size: larger;}
small {font-size: smaller;}

/* Replaced elements */
input, textarea {display: inline-block;}

值得留意的是,IE6的許多呈現值會受到 hasLayout 屬性影響,這正是不少IE6排版bug的根源。理解這些預設值與其背後機制,往往能讓除錯事半功倍。

XML學習教程| jQuery入門知識| AJAX入門| Dreamweaver教程| Fireworks入門知識| SEO技巧| SEO優化集錦|
Copyright © DIV+CSS佈局教程網 All Rights Reserved