Dynamically resize div for background image
问题 I have a background image in a header that automatically resizes to the width of the window. However, the height does not adjust properly -- an inherited CSS property sets the div to a fixed height of 50px. Currently, I'm using: background-size: cover; I can specify a fixed height for the div that will be observed, but then the background is only correct at a specific window size. If I set the size to auto or 100%, it goes to 50px; How can I make it ignore the height it thinks it should be