CSS3渐变与背景图像?可能?

时间:2011-09-21 18:30:17

标签: css css3 gradients

  

可能重复:
  Is it possible to combine a background image and CSS3 gradients?

我正在使用CSS作为背景渐变:

 background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #95d7d3), color-stop(1, #7db1ad) );
 background:-moz-linear-gradient( center top, #95d7d3 5%, #7db1ad 100% );
 filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#95d7d3', endColorstr='#7db1ad');

但我还想添加背景图片,有没有办法用这些渐变来做到这一点?

如果我使用它:

background: -moz-linear-gradient( center top, #95D7D3 5%, #7DB1AD 100% ) url(../img/icons.png) 0 -293px no-repeat!important;

渐变覆盖背景图像。

任何想法?

2 个答案:

答案 0 :(得分:-1)

background:url(../ img / icons.png), - moz-linear-gradient(中心顶部,#95D7D3 5%,#7DB1AD 100%);

答案 1 :(得分:-1)

以下链接是否有用:

http://css3.mikeplate.com/

相关问题