DIV的背景图像溢出 [英] DIV background-image overflow
本文介绍了DIV的背景图像溢出的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个背景图像的DIV元素,我希望它的DIV的尺寸外溢出(现在切断图像,因为图像比DIV大)。
I have a DIV element with a background-image, and I want it to overflow outside the dimensions of the DIV (it now cuts off the image because the image is bigger than the DIV).
这可能吗? 溢出:可见
不起作用
推荐答案
可以做到在另一种方式:
You can do it in alternative way:
#box {
margin:-50px 0 0;
padding:50px 0 0 0;
background:url(/images/image.png) no-repeat;
}
这篇关于DIV的背景图像溢出的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文