我正在尝试将CSS3Pie应用于div。我需要圆角(包括边界)和背景的线性渐变。我将它与另一个只需要圆角的DIV一起使用,但是当我将htc行为应用于此div时,所有发生的就是边框消失了。任何简单的方法来解决这个问题?
Demo
.productBoxes {
position: relative;
-webkit-border-radius: 15px;
border-radius: 15px;
background: #efefef; /* Old browsers */
background: -moz-linear-gradient(top, #efefef 0%, #efefef 3%, #e6e6e6 6%, #dbdbdb 13%, #d9d9d9 15%, #d4d4d4 17%, #cccccc 28%, #c7c7c7 49%, #c7c7c7 84%, #b8b8b8 92%, #b0b0b0 95%, #b0b0b0 96%, #adadad 96%, #ababab 98%, #a5a5a5 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#efefef), color-stop(3%,#efefef), color-stop(6%,#e6e6e6), color-stop(13%,#dbdbdb), color-stop(15%,#d9d9d9), color-stop(17%,#d4d4d4), color-stop(28%,#cccccc), color-stop(49%,#c7c7c7), color-stop(84%,#c7c7c7), color-stop(92%,#b8b8b8), color-stop(95%,#b0b0b0), color-stop(96%,#b0b0b0), color-stop(96%,#adadad), color-stop(98%,#ababab), color-stop(100%,#a5a5a5)); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top, #efefef 0%,#efefef 3%,#e6e6e6 6%,#dbdbdb 13%,#d9d9d9 15%,#d4d4d4 17%,#cccccc 28%,#c7c7c7 49%,#c7c7c7 84%,#b8b8b8 92%,#b0b0b0 95%,#b0b0b0 96%,#adadad 96%,#ababab 98%,#a5a5a5 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(top, #efefef 0%,#efefef 3%,#e6e6e6 6%,#dbdbdb 13%,#d9d9d9 15%,#d4d4d4 17%,#cccccc 28%,#c7c7c7 49%,#c7c7c7 84%,#b8b8b8 92%,#b0b0b0 95%,#b0b0b0 96%,#adadad 96%,#ababab 98%,#a5a5a5 100%); /* Opera 11.10+ */
background: -ms-linear-gradient(top, #efefef 0%,#efefef 3%,#e6e6e6 6%,#dbdbdb 13%,#d9d9d9 15%,#d4d4d4 17%,#cccccc 28%,#c7c7c7 49%,#c7c7c7 84%,#b8b8b8 92%,#b0b0b0 95%,#b0b0b0 96%,#adadad 96%,#ababab 98%,#a5a5a5 100%); /* IE10+ */
background: linear-gradient(top, #efefef 0%,#efefef 3%,#e6e6e6 6%,#dbdbdb 13%,#d9d9d9 15%,#d4d4d4 17%,#cccccc 28%,#c7c7c7 49%,#c7c7c7 84%,#b8b8b8 92%,#b0b0b0 95%,#b0b0b0 96%,#adadad 96%,#ababab 98%,#a5a5a5 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#efefef', endColorstr='#a5a5a5',GradientType=0 ); /* IE6-9 */
width: 100%;
padding: 0px;
margin: 0px;
margin-bottom: 1%;
border: 1px solid black;
overflow: hidden;
behavior: url(/PIE.htc);
}
最佳答案
尝试向元素添加zoom:1并为其赋予z-index
关于internet-explorer - CSS3Pie不适用,而是边框消失了,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/11527196/