1.background-repeat:
参数:
repeat:背景图像在纵向和横向上平铺
no-repeat:不平铺
repeat-x:横向平铺
repeat-y:纵向平铺
注意:设置或检索对象的背景图像是否以及如何铺排,必须先指定对象的背景图像。
对应的脚本特性为backgroundRepeat。
body {
background-color: pink;
background-image: url(../images/1.jpg);
background-repeat: repeat-x;
}
2.backgroud-position
语法:backgroud-position:length||length
backgroud-position:position||position
参数:length:百分数|由浮点数和单位标识符组成的长度值
position:top|center|botton|left|center|right
注意:设置或检索对象的背景图片的位置,必须先指定background-image属性,默认值为(0%,0%)。
该属性的定位不受对象的补丁属性(padding)的影响。