相关疑难解决方法(0)

为什么伪元素上的滤镜渐变在IE8中不起作用?

我想创建这样的按钮:
伪3d按钮

在现代浏览器中,使用插入框阴影和滤镜创建效果.
对于IE8 - 选择伪元素.
对于IE7 - 我使用包含在条件注释中的特殊标签.

演示:(http://jsfiddle.net/8M5Tt/68/)

/**
 * Button w/o images
 */
html {
    font-size: 62.5%;
    }
body {
    font: normal 1em/1em Arial, Tahoma, Verdana, sans-serif;
    }
 
/* layout */
.btn {
    display: inline-block;
    height: 28px;
    border-width: 1px;
    border-style: solid;
    width: 170px;
    box-sizing: content-box;
    overflow: hidden;
    position: relative;
    z-index: 1;
    }
.btn {
    margin: 15px;
    }
.btn.btn_small {
    width: 130px;
    }

/* ie7 */
.lt-ie8 .btn .before,
.lt-ie8 .btn .after {
    position: absolute;
    right: …
Run Code Online (Sandbox Code Playgroud)

html css internet-explorer-8 pseudo-element

35
推荐指数
2
解决办法
8064
查看次数

标签 统计

css ×1

html ×1

internet-explorer-8 ×1

pseudo-element ×1