Transparent Background Image with a Gradient

前端 未结 6 1912
庸人自扰
庸人自扰 2020-12-08 07:07

Today I was designing a transparent PNG background that would only sit in the top left of a div, and the rest of the div would maintain a gradient background for all transpa

6条回答
  •  孤街浪徒
    2020-12-08 07:47

    This is possible using multiple background syntax:

    .example3 {
        background-image: url(../images/plus.png), -moz-linear-gradient(top,  #cbe3ba,  #a6cc8b);
        background-image: url(../images/plus.png), -webkit-gradient(linear, left top, left bottom, from(#cbe3ba), to(#a6cc8b));
    }
    

    I read about this at Here's One Solution.

提交回复
热议问题