css 默认
先写全局的样式
body { margin:0 auto; font-size:12px; font-family:Verdana; line-height:1.5;}
ul,dl,dd,h1,h2,h3,h4,h5,h6,form,p { padding:; margin:;}
ul { list-style:none;}
img { border:0px;}
a { color:#05a; text-decoration:none;}
a:hover { color:#f00;}
全局的样式定义完后,下面定义以上几大块的样式,先设置下#containerr的样式如下:
#container { width:900px; margin:0 auto;}
body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, button, textarea, p, blockquote, th, td { margin:; padding:; }
fieldset, img { border:; }
:focus { outline:; }
h1, h2, h3, h4, h5, h6 { font-size: 100%; font-weight: normal; }
input, button, textarea, select, optgroup, option { font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; }
input, button, textarea, select { *font-size: 100%;}
textarea { overflow:auto; }
body { line-height: 1.5; }
ol, ul { list-style: none; }
:link, :visited, ins { text-decoration: none; }
body {
font: 14px/1.5 "Microsoft Yahei", "Hiragino Sans GB", Helvetica, "Helvetica Neue", "微软雅黑", Tahoma, Arial, sans-serif;
color: #14191e;
}
a链接样式
a:link {color: #FF0000} /* 未访问的链接 */
a:visited {color: #00FF00} /* 已访问的链接 */
a:hover {color: #FF00FF} /* 鼠标移动到链接上 */
a:active {color: #0000FF} /* 选定的链接 */
a { display: block; height: 30px; width: 100px; line-height: 30px; text-align: center; background: #CCC; }
a:hover { color: #FFF; text-decoration: none; background: #333; }
css 默认的更多相关文章
- Normalize.css:优化重置CSS默认属性
Normalize.css:优化重置CSS默认属性 官方网站:http://necolas.github.io/normalize.css/ 项目仓库:https://github.com/necol ...
- web 开发 css 默认值列表
css默认值列表 HTML标签CSS属性默认值汇总 这个东西,在你需要还原默认值的时候,比较有用. 开始的时候 *{margin:0;padding:0;},当需要使用边距的时候,就需要还原HTML默 ...
- css默认值汇总
原文:http://www.cnblogs.com/xiangzi888/archive/2011/10/12/2209514.html HTML标签CSS属性默认值汇总 这个东西,在你需要还原默认值 ...
- HTML标签CSS默认值研究
最近写css的时候,发现在div元素里面添加ul元素后发现,ul列表在div里面距离最上方总是有一段空行,当时很奇怪,以为是哪个css出了问题,就把css去掉了,发现问题依旧,然后就查了一下发现htm ...
- css默认被后代inherite的属性列表
css中的属性大部分都可以被继承,但是也有众多不能被继承,比如display, position,,left,right,top,bottom,float,width,border-color,bor ...
- 前端学习 -- Css -- 默认样式
浏览器为了在页面中没有样式时,也可以有一个比较好的显示效果, 所以为很多的元素都设置了一些默认的margin和padding,而它的这些默认样式,正常情况下我们是不需要使用的. 所以我们往往在编写样式 ...
- css默认样式
html, address,blockquote,body, dd, div,dl, dt, fieldset, form,frame, frameset,h1, h2, h3, h4,h5, h6, ...
- CSS默认可继承样式
前面的话 一直想总结出一份可继承样式的列表.常听说,颜色和字体是可继承的,盒模型样式是不可继承的,但其他样式呢?本文内容包括所有可继承的样式 [注意]关于样式的详细信息移步至此 常用可继承样式 col ...
- css 默认样式
body,textarea,input,select,option {font-size:12px;color:#333;font-family:Tahoma,Arial,sans-serif;} h ...
随机推荐
- Core Java Volume I — 4.1. Introduction to Object-Oriented Programming
4.1. Introduction to Object-Oriented ProgrammingObject-oriented programming, or OOP for short, is th ...
- apt-get 的常用使用说明
API神命令: apt-get -h >>help.txt apt 1.0.10.2ubuntu1,用于 amd64 体系结构,编译于 Oct 5 2015 15:55:05用法: apt ...
- 尽量多的以 const/enum/inline 替代 #define
前言 在面向过程语言,如 C 语言中,#define 非常常见,也确实好用,值得提倡.但在如今面向对象的语言,如 C++ 语言中,#define 就要尽量少用了. 为何在 C++ 中就要少用了呢? 这 ...
- cuffdiff 和 edgeR 对差异表达基因的描述
ASE又走到了关键的一步 要生成能决定是否有差异表达的table. 准备借鉴一下cuffdiff和edgeR 的结果 cuffdiff对差异表达基因的描述: 一共十四列: 第一列, test_id ...
- Alice and Bob
类似于石子合并的游戏,在黑板上写下N个数,每次只能将其中的一个数减1(结果为0自动消去),或者将某两个数消去,将其和写在黑板上. Alice先手,彼此都采用最优策略,将最后一个数消去者获胜. 思路:设 ...
- Codeforces 106 C 多重背包
题目链接:http://codeforces.com/problemset/problem/106/C 根据题意列出式子,设每种蛋糕做了xi个,则对于每种材料bi*xi<=ai. 对于dough ...
- JS初学之-自定义属性(索引值)
重点:1.添加索引值的作用:建立匹配.对应的关系. 比如:使每一个按钮对应数组里的每一张图,arrImg[this.index]. 2.不要在for循环的函数里面使用i. 3.添加索引值的方法aBtn ...
- hihoCoder:#1079(线段树+离散化)
题目大意:给n个区间,有的区间可能覆盖掉其他区间,问没有完全被其他区间覆盖的区间有几个?区间依次给出,如果有两个区间完全一样,则视为后面的覆盖前面的. 题目分析:区间可能很长,所以要将其离散化.但离散 ...
- Visual Studio 2012 离线升级包的制作
通过CMD执行“VS2012.3.exe/layout”命令,就可以把在线升级的文件保存到本地,这样一来,只要把下载出来的文件打包上传,然后分享出去,所谓的“VS2012 Update 3 离线升级包 ...
- away3d学习
http://www.cnblogs.com/flash3d/p/3403109.html M3U8文件简介:http://blog.sina.com.cn/s/blog_6cf7acdf0102v0 ...