How can I get gradients working in IE9?

Posted by gladoscc on Stack Overflow See other posts from Stack Overflow or by gladoscc
Published on 2012-10-29T22:22:54Z Indexed on 2012/10/29 23:01 UTC
Read the original article Hit count: 167

Filed under:
|
|

CSS:

.silver {
color: #636363;
border: solid 1px #9C9C9C;
background: #D6D6D6;

/*important part*/
background: -webkit-gradient(linear, left top, left bottom, from(#E8E8E8), to(#BABABA));
background: -moz-linear-gradient(top,  #E8E8E8,  #BABABA);
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr='#e8e8e8', endColorstr='#bababa')";
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#e8e8e8', endColorstr='#bababa');

padding: 2px 5px 2px 5px;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
border-radius: 5px;
margin-right: 5px;
font-size: 95%;
}

This works when I apply to class to a input / submit button, but the gradients do not display when I apply the class to a span or div. How can I get gradients working in IE9?

© Stack Overflow or respective owner

Related posts about css

Related posts about internet-explorer