IE7 float right导致父元素占用全宽 [英] IE7 float right causes parent element to take up full width

查看:151
本文介绍了IE7 float right导致父元素占用全宽的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我完全对此感到困惑,并没有完全理解IE7的问题。有问题的页面是此处,我在谈论顶部的灰色菜单栏。在所有其他合理的现代浏览器,它看起来很好。在IE7(也可能是IE6,但我们不支持) div.navArrow 元素有 float:right


$ b>


$ b>

$ b

我不知道从哪里开始修复这个。有任何想法吗?

解决方案

我实际上通过应用一个特殊的css为IE7及以下。我给父母< li> a float:right style和 div.navArrow a float:none 。这似乎做的伎俩。


I am completely baffled by this and don't fully understand IE7's problem. The page in question is here and I'm talking about the top grey menu bar. On all other reasonably modern browsers it looks just fine. On IE7 (and possibly IE6 too, but we don't support that) the div.navArrow element having float:right gets pused all the way to the right, making the parent element <li> take up the remaining width of the page.

I'm not sure where to start in fixing this. Any ideas please?

解决方案

I have actually fixed this by applying an special css for IE7 and below. I gave the parent <li> a float:right style, and div.navArrow a float:none. That seemed to do the trick.

这篇关于IE7 float right导致父元素占用全宽的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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