I'm trying to create a div of variable height which would have 2 backgrounds colors:
- one background covering its whole surface
- one background starting 30% from the top of the window and which height would be 70% of the window (not the div). This background would be fixed on scroll.
I've tried everything and still can't find a good way to do this, even when playing with background images. I'd like to avoid position: fixed
if possible. and stick with background-attachment: fixed
.
Here is the effect I would like to get: http://jsbin.com/gabuvakegane/1/
Is there any way I can this easily done, with a decent browser support (IE9 required) ?