Setting div hight respective of screen height via jquery
问题 I have been told to use JS to resolve my issue: My issue is that I have 2 divs content and sidebar with the height set to 100%, I have a footer located underneath. My issue is that on my laptop I would like the page to show without a scroll and on a full page3, if there is more data the page will then require a scroll. How could I set the div height determined to my screen resolution? 回答1: You can do this in pure HTML/CSS - no JavaScript required. What you're after is a cross-browser sticky