Heim  >  Artikel  >  Web-Frontend  >  对于CSS中 background:transparent none repeat scroll 0% 0%;的理解_html/css_WEB-ITnose

对于CSS中 background:transparent none repeat scroll 0% 0%;的理解_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:47:451452Durchsuche

对于很多人对    BACKGROUND: none transparent scroll repeat 0% 0%;这样的写法是错误的

但是系统会帮你解释成下面这样。
BACKGROUND:transparent none repeat scroll 0% 0%;

分别代表
背景属性:背景颜色 背景图片 背景是否重复 背景时候随浏览器滚动 背景平位置 背景垂直位置
background : background-color || background-image || background-repeat || background-attachment || background-position

transparent表示透明无颜色
none 表示没有设置背景图片
repeat 表示图片重复
scroll 表示背景图片随浏览器下拉而滚动
0%水平位置在x0
0%垂直位置在y0

这个设置是background 的默认设置 ,
也就是说 没有对background属性进行设置的时候 他就会使用这用设置。
Stellungnahme:
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn