背景图片不显示右下角
CSS中有些东西我不知道?我正在尝试在屏幕的右下角放置一张图片。我不知道它为什么这样做,但它似乎将图像从屏幕上推开,我看不到它。如果我删除bottom
,它会将图像放在右侧,但不会放在底部。如果我做right top
图片显示在右上角。那么为什么它不显示在right bottom
?背景图片不显示右下角
*{
box-sizing: border-box;
font-family: BentonSans, 'Lucida Sans', 'Lucida Grande', sans-serif;
color: rgb(102, 102, 102);
outline: none;
border: 0;
}
body{
font-size: 12pt;
padding: 0;
margin: 0;
background-image: url("/media/images/image1.jpg");
background-position: right bottom;
background-repeat: no-repeat;
}
我怀疑它是与容器大小有关。
你有没有在你的CSS somehwere?
html, body {
min-height: 100%;
min-width: 100%;
}
是!我也刚刚找到解决方案! – 2013-03-13 00:58:06
我认为'min-height'和'min-width'会更好。 – 2013-03-13 00:58:47
正确的你是...更新 – hammus 2013-03-13 00:59:33
怎么样演示? – xiaoyi 2013-03-13 00:55:34