css将背景图片固定在网页右下角
将背景图片固定在右下角,一般是因为网页需要这样,才能显得美观和其他样式契合。
但是如果使用普通的css代码,只能将背景在网页中平铺。
想达到在右下角固定的效果,代码稍微麻烦一些。
css代码<style>
body {
background-color: #e8dabf;
background-image: url(1.jpg);
background-position: bottom right, top;
background-repeat: no-repeat, repeat;
background-attachment: fixed, scroll;
}
</style>