【问题标题】:a div with height:1px appears very thicker in internet explorer 6. How to reduce it?一个高度:1px 的 div 在 Internet Explorer 6 中显得非常厚。如何减少它?
【发布时间】:2013-09-10 08:14:18
【问题描述】:

这是我的 CSS 属性:

.line-separator {
height: 1px;
background: #d2d2d2;
border-bottom: 0px solid WindowFrame;
color: #d2d2d2;
width: 984px;
    }

这是我的 DIV:(我在底部使用了类似这样的一个。)

<div class="line-separator" style="margin-left: 3px;">
</div>

IE 7:这是必需的外观

IE 6:看起来很厚。不应该是这样。

请避免使用 ie6 之类的 cmets 或继续使用等,我知道它会灭绝。我在ie6中有一个要求。如何解决?

【问题讨论】:

    标签: html css internet-explorer internet-explorer-6


    【解决方案1】:

    添加line-height: 1pxoverflow: hidden。这样就可以了。

    【讨论】:

    • 我认为overflow: none 不被任何浏览器识别。
    • 在添加额外的 CSS 之前,请尽量不要在开始标签和结束标签之间留下任何空格:&lt;div class="line-separator"&gt;&lt;/div&gt;
    • @BoltClock 你是对的。我想说overflow: hidden,但我有点心烦意乱。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2015-05-09
    • 2022-01-08
    • 2011-06-12
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多