NEWS
建网站知识【CSS背景属性】 CSS 背景 (background) 属性定义元素的背景效果。 元素的背景区包括前景之下直到边框边界的所有空间。因此,内容框与内边距都是元素背景的一部分,且边框画在背景上。 CSS允许应用纯色作为背景,也允许使用背景图像创建相当复杂的效果;CSS在这方面的能力远远在 HTM......广州建网站www.3goweb.cn三行网络公司为您详细介绍 - 请往下阅读》
CSS 背景 (background) 属性定义元素的背景效果。
元素的背景区包括前景之下直到边框边界的所有空间。因此,内容框与内边距都是元素背景的一部分,且边框画在背景上。
CSS允许应用纯色作为背景,也允许使用背景图像创建相当复杂的效果;CSS在这方面的能力远远在 HTML 之上。
CSS 背景属性属性 描述 值
background 简写属性,作用是将背景属性设置在一个声明中。 background-color
background-image
background-repeat
background-attachment
background-position
background-attachment 背景图像是否固定或者随着页面的其余部分滚动。 scroll
fixed
background-color 设置元素的背景颜色。 color-rgb
color-hex
color-name
transparent
background-image 把图像设置为背景。 url
none
background-position 设置背景图像的起始位置。 top left
top center
top right
center left
center center
center right
bottom left
bottom center
bottom right
x-% y-%
x-pos y-pos
background-repeat 设置背景图像是否及如何重复。 repeat
repeat-x
repeat-y
no-repeat
no-repeat
【关键词标签】CSS背景属性
匠心打造精品,用心成就经典!携手客户共创双赢! © Copyright 广州三行网络科技有限公司 粤ICP备案号:09210325