问答文章1 问答文章501 问答文章1001 问答文章1501 问答文章2001 问答文章2501 问答文章3001 问答文章3501 问答文章4001 问答文章4501 问答文章5001 问答文章5501 问答文章6001 问答文章6501 问答文章7001 问答文章7501 问答文章8001 问答文章8501 问答文章9001 问答文章9501

CSS初始化的代码怎么写

发布网友 发布时间:2022-05-07 15:11

我来回答

1个回答

热心网友 时间:2022-04-20 14:27

最耗资源的,最简单的

* { padding: 0; margin: 0; border: 0; }

选择性初始化举例(综合)

body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,legend,button

form,fieldset,input,textarea,p,blockquote,th,td {   

  padding: 0;   

  margin: 0;   

}

 3. 参考新浪、雅虎

/* 新浪全局样式 */

body,ul,ol,li,p,h1,h2,h3,h4,h5,h6,form,fieldset,table,td,img,div{

    margin:0;padding:0;border:0;

}

body{

    background:#fff;color:#333;font-size:12px; margin-top:5px;font-family:"SimSun","宋体","Arial Narrow";

}

ul,ol{

    list-style-type:none;

}

select,input,img,select{

    vertical-align:middle;

}

a{text-decoration:none;}

a:link{color:#009;}

a:visited{color:#800080;}

a:hover,a:active,a:focus{color:#c00;text-decoration:underline;}


/* 雅虎全局样式 */

html {

    background: none repeat scroll 0 0 #FFFFFF;

    color: #000000;

}

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 none;

}

address, caption, cite, code, dfn, em, strong, th, var {

    font-style: normal;

    font-weight: normal;

}

li {

    list-style: none outside 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 none;

    font-variant: normal;

}

sup {

    vertical-align: text-top;

}

sub {

    vertical-align: text-bottom;

}

input, textarea, select {

    font-family: inherit;

    font-size: inherit;

    font-weight: inherit;

}

input, textarea, select {

}

legend {

    color: #000000;

}

body {

    font: 13px/1.231 arial,helvetica,clean,sans-serif;

}

select, input, button, textarea {

    font: 99% arial,helvetica,clean,sans-serif;

}

table {

    font-size: inherit;

}

pre, code, kbd, samp, tt {

    font-family: monospace;

    line-height: 100%;

}

a {

    text-decoration: none;

}

a:hover, a:focus {

    text-decoration: underline;

}

strong {

    font-weight: bold;

}

input[type="submit"] {

    cursor: pointer;

}

button {

    cursor: pointer;

}

声明声明:本网页内容为用户发布,旨在传播知识,不代表本网认同其观点,若有侵权等问题请及时与本网联系,我们将在第一时间删除处理。E-MAIL:11247931@qq.com
墨兰烂根是怎么回事 墨兰烂根后如何养护 谢绝推销参观拍照摄影看房预约 看房子为什么不让拍照 执业药师各科考试时间分配 执业药师考试倒计时100天,怎样备考最有效 中药执业药师怎么备考? 手机拒绝所有来电了怎么设置回来 美国狼人在伦敦演职员表 美国狼人在伦敦幕后制作 美国狼人在伦敦制作发行 css页面的初始化作用是什么? CSS怎么初始化 为什么要初始化css? 企业清算其他应收款的处理 王者荣耀新版半肉阿轲怎么玩厉害 新版半肉阿轲进阶 QQ王者荣耀阿轲打野怎么玩 阿轲打野方法详解 王者荣耀。阿轲。 三角函数 正割与余弦的关系 正弦,余弦,正切,余切,正割,余割的联系与区别? 三角函数中正割余割与正弦,正切,余弦,余切有啥关系 正割与余弦的关系 本位币金额不平衡是什么意思 金蝶软件怎么设置美元为本位币 金蝶EAS中,修改凭证后显示本位币金额不等于辅助账金额之和,但是实际上是相等的,怎么解决?求解 金蝶软件安装输入人民币本位币显示代码超长,长度应设为三位数是什么意思 为什么我的电脑装上金蝶2000后在新建账套步骤里它弹出本位币识别过长可是我的就是3位,而且装到其他电脑就 金蝶KIS标准版核算单一外币初始化录入 在金蝶里,因为以前的会计在期末调汇时,用手工进行调汇的,币别是人民币!可是在调数据选择“综合本位币 金蝶凭证打印为什么凭证理有借方本位币,贷方本位币 金蝶软件固定资产本位币和原值不一样是怎么回事 css初始化代码怎么用 css初始化是什么意思 欧佩七件套怎么用 css初始化font-size和line-height是为了什么 为什么要初始化CSS Web前端面试指导(十六):为什么要初始化CSS 欧佩熬夜滋润眼精华是什么时候用? 怎么找css初始化diamante css在初始化时为什么写成h1,h2,h3,h4,h5,h6{font-size:1em;}是1em... Web前端面试题:为什么要初始化CSS样式 欧佩肌肽酵母沁润嫩肤的使用步骤 欧佩臻美亮颜修护九件套怎么样- 问一问 CSS初始化失效 梦见蛇吞蛇,自己再吞了一根蛇是什么预示 太康县新农合服务大厅电话 在家帮老公剪头发技巧是怎样的? 给男生理发要怎么理?有什么要注意的? 男的理平头,合适吗? 怎么把下载到电脑的照片传送到mp4? 如何下载图片到MP4上?