ie6、7、8兼容部分css3

做法很简单下载一个ie-css3,然后有css3的样式里加入behavior: url(js/ie-css3.htc)就可以了(js/ie-css3.htc是文件地址)

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title></title>
<style type="text/css">
.border_radius{
    100px;
    height:100px;
    background: #6AAFCF;
    border-radius: 25px;
    box-shadow:1px 5px 5px 5px #ccc;
    -moz-border-radius: 25px; /* For Firefox Browser */
    -webkit-border-radius: 25px; /* For Safari and Google Chrome Browser */
    -o-border-radius: 25px; /* For Opera Browser */ 
    behavior: url(js/ie-css3.htc); 
}
</style>
</head>

<body>
<div class="border_radius"></div>
</body>
</html>

测试结果在ie7和ie8都是圆角带有阴影,缺点是阴影颜色默认是黑色不能更改

原文地址:https://www.cnblogs.com/wlyj/p/5806993.html