Forum Moderators: not2easy

Message Too Old, No Replies

Nested Scroll Bar

         

moesian

12:24 pm on May 31, 2007 (gmt 0)

10+ Year Member



Hi,

Is it possible just using CSS to create a new nested scroll bar within a page? Or is this something that you would have to do with javascript?

What would be the best option for such a thing?

Thanks

Robin_reala

12:49 pm on May 31, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Not too difficult. Make an element, give it fixed dimensions and
overflow:auto
. Then, when you put more content in it that it has space for, it'll gain a scrollbar. If you want a scrollbar all the time then you can use
overflow:scroll
but that'll give you a vertical and horizontal scrollbar. Luckily IE and Firefox both support CSS3's
overflow-x
and
overflow-y
which let you fine-tune the appearance.

moesian

12:59 pm on May 31, 2007 (gmt 0)

10+ Year Member



Thanks alot, will the overflow:auto work in IE6?

Robin_reala

1:04 pm on May 31, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Yep.