IE displays a default scrollbar on the page, which appears even if the content is too short to require a scrollbar.
The typical way to remove this scrollbar (if not needed), is to add this to your CSS:
html {
height: 100%;
overflow: auto;
}
I'm trying to do the same thing in Javascript (without requiring that in my CSS), but I can't seem to find a way to get access to the <html>
element. I know I can access the <body>
element with document.body
, but that doesn't seem to be sufficient, I need the wrapping <html>
element.
Any tips?