문제

I have a site which needs to be fully self-contained in the browser window, ie, the user must not have to scroll up and down to view different parts of the site. Content that is too long to fit into the content pane is handled with overflow:auto, which is working fine.

the problem is, no matter what I try I still have the following problem:

two sets of scrollbars http://www.wikiforall.net/bad_scrollbars.png

So beneaht the content which successfully fills the browser window, there seems to be a gap. This gap causes the vertical scrollbar to show itself (and there appears to be a similar gap on the right side which isn't as easy to see). I've inspected the elements using Chrome's element inspector and the <html> tag covers only up to that gap. So I have no idea where the gap is coming from.

The main page divs are setup with position: absolute, with left, right, top, and bottom all set to zero. These divs also have display: inline set, and do not have margins or padding. The html and body tags are styled the same way.

I've been looking around for a day or two but nothing I've found has worked. Does anyone know how to remove these scrollbars?

도움이 되었습니까?

해결책

You can always use:

overflow: hidden;

To hide the scrollbars.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top