background-attachment
DIV+CSS 2009/5/25 20:52:51 点击:不统计
语法:
background-attachment : scroll | fixed
取值:
scroll : 默认值。背景图像是随对象内容滚动
fixed : 背景图像固定
说明:
设置或检索背景图像是随对象内容滚动还是固定的。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
请参阅 bgProperties 属性(特性)。对应的脚本特性为 backgroundAttachment 。
示例:
html { background-image: url("anasazi.tif"); background-attachment: fixed; }
body { background-attachment: scroll; }
·上一篇:background >> ·下一篇:css:继承的利与弊 >>