新手的话,我给几个意见吧 ,做前端开发之前,建议先写上一段css重写代码,以防止有些不兼容的标签导致一些问题。
命名规范给一些意见来自thinkcss
-----------------------------------------------------------------
* $codex 1. id和class命名采用该版块的英文单词或组合命名,并第一个单词小写,第二个单词首个字母大写,如:thinkCss(最新产品/think+Css)
* $codex 2. CSS样式表各区块用注释说明
* $codex 3. 尽量使用英文命名原则
* $codex 4. 尽量不加中杠和下划线
* $codex 5. 尽量不缩写,除非一看就明白的单词
css重写代码来自渴切(Cutter)-开源中文css框架
--------------------------------------------------------------------
/body, select, input, textarea {
color:#4f4f4f; font-family:Verdana, Arial, Helvetica, sans-serif;
}
body{ background:#fff; line-height:22px;}
* {}
a{outline:none; text-decoration:none; color:#4f4f4f;} a:hover{ text-decoration:underline; color:#fe5900;}
html{zoom:1;}html *{outline:0;zoom:1;} html button::-moz-focus-inner{border-color:transparent!important;}
body{overflow-x: hidden; font-size:12px;} 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,a img{border:0;} address,caption,cite,code,dfn,em,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:'';}
本文如未解决您的问题请添加抖音号:51dongshi(抖音搜索懂视),直接咨询即可。