I need to attach multiple backgrounds to an element via CSS and I can't use :before/:after
.
I'm wondering what the correct syntax to use multiple CSS background image is.
There is a bunch of suggested ways I found, like here or here, but I can get neither of these:
background: url(…) 0 0 repeat, url(…) 5px 5px no-repeat #FFF;
background: url(…) 600px 10px no-repeat, url(…) 10px 10px no-repeat;
to work.
This is what I currently have:
background-image: rgba(0, 0, 0, 0.4) url("img/icons-18-white.png") no-repeat 0% 50%,linear-gradient( #9ad945, #7eb238 );
which is ignored. Only when I supply the pure url, it works:
background-image: url("img/icons-18-white.png") , linear-gradient( #9ad945, #7eb238 );
Question:
I'm specifically looking for a way to set background-size/position/repeat
per image, so if someone could point me to the correct syntax, would be really nice!
EDIT:
Adding scroll
and replacing background-image
with background
background: rgba(0, 0, 0, 0.4) url("http://code.jquery.com/mobile/1.3.0/images/icons-18-white.png") no-repeat scroll 0% 50%, linear-gradient( #9ad945, #7eb238 );
does not work.