CSS dashed border always appears white in IE8, why

2019-08-18 22:10发布

Here is the deal, I have following div with dashed borders:

.dashed-header {
    /*background-color: transparent;*/
    height: 87px;
    margin-top: 5px;
    border-top: 1px dashed #613e27;
    border-bottom: 1px dashed #613e27;
}

for some reason border is white instead of #613e27 and I have no idea why it is so? Here is my webpage You can see this border in dark brown header line.

2条回答
家丑人穷心不美
2楼-- · 2019-08-18 22:57

Try using:

border-color: #613e27 !important;
查看更多
仙女界的扛把子
3楼-- · 2019-08-18 23:07

I have IE8 and it work fine, I put it inside another div to see if the color disappear or not, but the color still exist

<style>
.main {
    height: 200px;
    width:200px;
    margin-top: 5px;
    border: 1px solid black;
    background-color:#A1Ae27;
    padding: 15px;
}
.dashed-header {
    /*background-color: transparent;*/
    height: 87px;
    width:100px;
    margin-top: 5px;
    border-top: 1px dashed #613e27;
    border-bottom: 1px dashed #613e27;
}
</style>
<body>

<div class="main">
    <div class="dashed-header">
    </div>
</div>
</body>

try to change to solid border and see does they appear whit too in your EI8?

查看更多
登录 后发表回答