【发布时间】:2012-03-26 03:24:53
【问题描述】:
我使用渐变作为按钮背景颜色,这仅适用于非 IE 浏览器。我正在尝试为 IE 设置纯色背景色。当我将背景样式放在样式表中的背景渐变之前,它根本不显示。当我把它放在之后,它会覆盖所有浏览器中的渐变。
没有它,我的按钮是完全透明的。有人可以帮我弄清楚如何只为 IE 提供背景颜色吗? (版本 8 和 9)或者甚至更好.. 设置渐变?
这是在 IE 以外的浏览器中工作的 CSS。但是,纯色背景根本没有出现:
button {
background: #3485bf;
background: -moz-linear-gradient(
top,
#59a3d4 0%,
#3485bf);
background: -webkit-gradient(
linear, left top, left bottom,
from(#59a3d4),
to(#3485bf));
}
【问题讨论】:
标签: css internet-explorer button internet-explorer-8 background-color