当前位置: 移动技术网 > IT编程>网页制作>CSS > 百度前端学院-基础学院-第四课

百度前端学院-基础学院-第四课

2018年04月28日  | 移动技术网IT编程  | 我要评论

今天是第四天,进度可以,表扬一下自己。

今天的课程目标是:掌握 CSS 稍微复杂的一些选择器,还有背景,边框等一些 CSS 样式属性。

CSS背景:

背景色:background-color:gray;

背景图:background-image:url(www.......);

背景颜色渐变:

div {
background-image: linear-gradient(to bottom, orange, yellow);
}

背景图像重复:background-repeat: repeat-y/x/no-repear;

背景图片定位:background-position:center(值有很多,可参考:http://www.w3school.com.cn/cssref/pr_background-position.asp

背景图片相对可视区固定: background-attachment:fixed; 默认值是scroll,随下拉图片滚动。

边框:

border-style: double; 边框样式,可以设置dashed等。

border-width:thick;设置边框宽度。

border-color: rgb(25%, 35%,45%); 设置边框颜色。如果设置为transparent,边框是透明的。

 

如对本文有疑问, 点击进行留言回复!!

相关文章:

验证码:
移动技术网