背景位置设置50%就等于设置center吗?
背景位置设置50%就等于设置center吗?50%不是指背景左上角的距离到定位点的距离么?
课程里面老师设置了center 50%就等于 50% 50%? 为什么显示效果图片在下半部分,儿上面是空的
另外 我这个代码 为什么写了背景颜色整个网页就显示不出来了呢?
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>background-image</title>
<style type="text/css">
div{
width:300px;
height:300px;
background:
#ef
url(http://img1.sycdn.imooc.com/climg//582c3b780001a95103000090.jpg) no-repeat center top
,url(http://img1.sycdn.imooc.com/climg//582c3b6d0001197603000090.jpg) no-repeat center center
,url(http://img1.sycdn.imooc.com/climg//582c3b61000122dd03000090.jpg) no-repeat center bottom;
}
</style>
</head>
<body>
<!-- 此处写代码 -->
<div></div>
</body>
</html>
恭喜解决一个难题,获得1积分~
来为老师/同学的回答评分吧
0 星