View Full Version : disabling horizontal scrollbars in scrolling divs

02-10-2004, 01:52 AM
So here's the problem:

<div style="overflow: scroll;">some text</div>

That displays with a horizontal scrollbar as well as a vertical scrollbar, even when the horizontal is not required. Is there any way to stop it from showing? I don't want to use a javascript scroller as they're plain nasty and means you can't use a scroll mouse with it, any ideas?

iframes are an alternative but again, not ideal as using sessions in PHP can (and will) cause problems whenever you use any kind of frame.

Thanks in advance,


02-10-2004, 02:36 AM
Try changing it to auto instead of scroll.

// freak

02-10-2004, 08:44 AM
If it wasn't proprietry code you could use

<div style="overflow-y: auto; overflow-x:none;">some text</div>