【问题标题】:CSS3 PIE Doesn't Work in IE8 or belowCSS3 PIE 在 IE8 或更低版本中不起作用
【发布时间】:2014-01-24 13:41:53
【问题描述】:

没有弯曲的边框。 IE9 及以上版本运行良好。

http://cscsu.org.uk/WiltshireMedicinesManagement/csu.htm 是我所拥有的非常精简的版本

<!DOCTYPE html>
<html lang="en-US">
<head>
<style type="text/css">

.wpdm-metro {
behavior:url(/border-radius.htc);
-moz-border-radius:8px;
-webkit-border-radius:8px;
-khtml-border-radius:8px;
border-radius:8px;
margin-bottom:2px;

margin: 0 5px 7px 0; 
height:120px; 
width:45%; 
background:#66cc33 !important; 
color:white !important;
}
</style>
</head>

<body>
<div class="wpdm-metro">
</div> 
</body>
</html>

我做错了什么吗?该文件存在(border-radius.htc),我什至在.htacccess 中添加了AddType text/x-component .htc

【问题讨论】:

    标签: css3pie


    【解决方案1】:

    无论出于何种原因,除非您从 background 规则中删除 !important,否则 PIE 将无法工作。

    虽然我没有在documentation 中看到过这一点,但在遇到几乎相同的问题时它对我有用。

    .wpdm-metro {
        behavior:url(/border-radius.htc);
       -moz-border-radius:8px;
       -webkit-border-radius:8px;
       -khtml-border-radius:8px;
        border-radius:8px;
        margin: 0 5px 7px 0; 
        height:120px; 
        width:45%; 
        background:#66cc33; 
        color:white;
    }
    

    【讨论】:

    • 太棒了……真的。谢谢。如果我需要它们怎么办?
    猜你喜欢
    • 2012-09-29
    • 1970-01-01
    • 2012-06-15
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2012-09-16
    • 2012-05-14
    • 2011-06-07
    相关资源
    最近更新 更多