绝对DIV中的图像不包含来自DIV的定位 [英] Image in absolute DIV is not positioning from containing DIV

查看:98
本文介绍了绝对DIV中的图像不包含来自DIV的定位的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个DIV,位置:绝对在另一个位置:相对。但是内部DIV正在流出另一个,并且基于浏览器而不是包含DIV来自我定位。任何想法为什么会发生这种情况?



您可以在这里看到问题:

https://www.luxedesignerhandbags.com/Articles.asp?ID=239



看看这个botton的权利为您的手袋获取现金

图片在div id =sell_bag中,包含在div id =wrapper中

css如下:

  #wrapper {
position:inherit;
font-family:流沙,Arial,Helvetica,sans-serif;
width:980px;
left:24px;
margin:auto;
}

#sell_bag {
position:absolute;
right:190px;
width:260px;

任何帮助都将不胜感激!



谢谢,

解决方案

position:relative on包含div


I have a DIV with position:absolute inside another with position:relative. But the inside DIV is flowing out of the other and positioning it self based on the browser not the containing DIV. Any ideas why this is happening?

You can see the problem here:

https://www.luxedesignerhandbags.com/Articles.asp?ID=239

Look at the botton right "Get Cash for your handbags"

The image is in div id="sell_bag" and that is contained in div id="wrapper"

The css is as follows:

#wrapper {
    position:inherit;
    font-family: Quicksand, Arial, Helvetica, sans-serif;
    width: 980px;
    left: 24px;
    margin: auto;
}

#sell_bag {
    position:absolute;
    right: 190px;
    width: 260px;
}

Any help would be greatly appreciated!

Thanks,

解决方案

position: relative on the containing div

这篇关于绝对DIV中的图像不包含来自DIV的定位的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆