CSS初始化代码_Div+CSS教程
1.
2.
- charset ”utf-8″;
- html {background:url(/www/pic/head_back.gif) repeat-x top #FFF}
- body {width:920px;font:12px Arial;margin:0 auto;padding:0;color:#000;}
- a{color:#000; text-decoration:none}
- a:hover {color:#f00; text-decoration:underline}
- ul,ol,p,dl{margin:0;padding:0}
- ul,ol,dl{height:100%;overflow:hidden}
- li{list-style:none}
- img {border:none}
- h1,h2,h3,h4{font:12px Verdana;margin:0;padding:0}
- input {font:12px Verdana}
- /*为背景定义了颜色*/
- /*html {
- color:#000;
- background:#FFF;
- }*/
- body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, textarea, p, blockquote, th, td {
- margin:0;
- padding:0;
- }
- /*合并边线,边线空间至零.*/
- table {
- border-collapse:collapse;
- border-spacing:0;
- }
- /*清除边线*/
- fieldset, img {
- border:0;
- }
- address, caption, cite, code, dfn, em, strong, th, var {
- font-style:normal;
- font-weight:normal;
- }
- li {
- list-style:none;
- }
- caption, th {
- text-align:left;
- }
- h1, h2, h3, h4, h5, h6 {
- font-size:100%;
- font-weight:normal;
- }
- /*添加空字符清除融合*/
- q:before, q:after {
- content:”;
- }
- abbr, acronym {
- border:0;
- font-variant:normal;
- }
- /* to preserve line-height and selector appearance */
- sup {
- vertical-align:text-top;
- }
- sub {
- vertical-align:text-bottom;
- }
- input, textarea, select {
- font-family:inherit;
- font-size:inherit;
- font-weight:inherit;
- }
- /*to enable resizing for IE*/
- /*在ie下重定义*/
- input, textarea, select {
- *font-size:100%;
- }
- /*because legend doesn’t inherit in IE */
- /*IE下legend不继承 */
- legend {
- color:#000;
- }
相关Div+CSS教程:
- 相关链接:
- 教程说明:
Div+CSS教程-CSS初始化代码。