我试图创建一个带有居中背景图片的页面,使用的是position center center。但是图片看起来似乎在垂直方向上超出了页面顶部,而没有水平居中。我在哪里或为什么出错了?
<!DOCTYPE html>
<html>
<style>
body
{
background-image:url('tumbleweed.jpg');
background-repeat:no-repeat;
background-position:center center;
background-color:#EAEAEA;
}
</style>
</html>