Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/38.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
IE css与新闻滚动的问题_Css_Internet Explorer 7_Ie8 Compatibility Mode - Fatal编程技术网

IE css与新闻滚动的问题

IE css与新闻滚动的问题,css,internet-explorer-7,ie8-compatibility-mode,Css,Internet Explorer 7,Ie8 Compatibility Mode,我们在右导航栏有一个新闻滚动条。它在FF和Chrome中工作得很好,但在IE中,新闻故事相互碰撞 有人能解释一下它到底出了什么问题吗?这似乎在IE8中正常工作,您使用的是什么版本 不管怎样,我可以把它复制到兼容模式或IE7模式 确定问题后,似乎正确设置了溢出:隐藏的容器div的高度非常大。这是我指的div: 我将高度设置为130px,似乎解决了这个问题。更有趣的问题是,为什么不是所有浏览器都会出现这种情况,我还没有进行调查。有时候IE版本和其他浏览器在像素间距方面存在差异。解决这一问题的办法是

我们在右导航栏有一个新闻滚动条。它在FF和Chrome中工作得很好,但在IE中,新闻故事相互碰撞


有人能解释一下它到底出了什么问题吗?

这似乎在IE8中正常工作,您使用的是什么版本

不管怎样,我可以把它复制到兼容模式或IE7模式

确定问题后,似乎正确设置了溢出:隐藏的容器
div
的高度非常大。这是我指的
div


我将高度设置为
130px
,似乎解决了这个问题。更有趣的问题是,为什么不是所有浏览器都会出现这种情况,我还没有进行调查。

有时候IE版本和其他浏览器在像素间距方面存在差异。解决这一问题的办法是为
ul
li
元素提供特定于IE的样式。我建议您将当前的css换行(不管):


添加
位置:相对
div.latest-news-container
看起来您在包含新闻的所有div上都有一个预定义的高度。在IE-9上,由于高度不足以容纳文本,文本会与每个文本相撞。。收缩文本或增加高度或限制字符数。噢,更新浏览器工作的原因是父容器的高度
class=“latest news container”
设置为高度135px,因此这会阻止子容器再长得更高。实际上,您可以从
class=“latest news content”
中完全删除高度,并让它增长到100%,在本例中,它的父级.div.latest-news-content li{height:134px;!important}解决了这个问题。
<ul style="top: -465px; height: 1380px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; list-style-type: none; position: relative; z-index: 1; ...

<li style="width: 199px; height: 115px; overflow: hidden; float: none; ...