css background学习
2017-07-06 17:23
162 查看
background中背景单词
background-color: 设置颜色作为对象背景颜色
background-image :设置图片作为背景图片
background-repeat :设置背景平铺重复方向
background-attachment 设置或检索背景图像是随对象内容滚动还是固定的。
background-position 设置或检索对象的背景图像位置。
使用方法
Background背景样式的值是复合属性值组合,也就是背景单词的值可以跟多个属性值,值与值之间使用一个空格间隔链接上即可。
如:
background:#000 url(图片地址) no-repeat left top
background-attachment使用解析:
background-attachment:fixed; 背景固定
background-attachment:scroll css背景图片是随对象内容滚动
background-position : 5px 6px div对象靠左距离5px,靠上距离6px
css背景资源地址
background-color: 设置颜色作为对象背景颜色
background-image :设置图片作为背景图片
background-repeat :设置背景平铺重复方向
background-attachment 设置或检索背景图像是随对象内容滚动还是固定的。
background-position 设置或检索对象的背景图像位置。
使用方法
Background背景样式的值是复合属性值组合,也就是背景单词的值可以跟多个属性值,值与值之间使用一个空格间隔链接上即可。
如:
background:#000 url(图片地址) no-repeat left top
background-attachment使用解析:
background-attachment:fixed; 背景固定
background-attachment:scroll css背景图片是随对象内容滚动
background-position : 5px 6px div对象靠左距离5px,靠上距离6px
css背景资源地址
相关文章推荐
- WEB标准学习路程之"CSS":3.背景Background属性
- CSS学习文档、CSS背景图片的定位background-position的问题
- 前端学习之css行高 font属性 伪类 background
- CSS学习:关于background-position
- 从零开始前端学习[9]:css中的背景样式background的使用
- css学习笔记之background-position
- 学习CSS的背景图像属性background
- CSS学习(八)-background-origin、background-clip
- html5-CSS学习-background记录
- 深入学习css之background属性
- HTML5学习_day01(5)--css常见样式background
- 学习CSS的背景图像属性background
- 前端_CSS#background-position学习
- 【CSS学习】CSS背景background、background-position使用详解
- CSS学习笔记13:background系列属性
- css学习总结(1)background之background-color
- 由布局学习CSS——从CSS sprites重视background
- H5学习之18 css-background
- 学习CSS中background-position的使用方法
- CSS学习小札-常用属性总结之background&&text