I have a footer div with 100% width. It\'s about 50px high, depending on its content.
Is it possible to give that #footer a background image that kind of overflows t
No, you can't.
But as a solid workaround, I would suggest to classify that first div as position:relative
and use div::before
to create an underlying element containing your image. Classified as position:absolute
you can move it anywhere relative to your initial div.
Don't forget to add content to that new element. Here's some example:
div {
position: relative;
}
div::before {
content: ""; /* empty but necessary */
position: absolute;
background: ...
}
Note: if you want it to be 'on top' of the parent div, use div::after
instead.