
Published in Website Design on Tuesday, 24 February 2009 |
Post RSS
While they don't (yet) validate, these can be used to control scrollbar display on all major browsers.
<div style="border: #002200 1px solid; padding:5px; overflow-y: scroll; overflow-x: hidden; width: 200px; height: 60px">
This is an example of one directional scrolling that uses the overflow-x and overflow-y properties.This is an example of one directional scrolling that uses the overflow-x and overflow-y properties.This is an example of one directional scrolling that uses the overflow-x and overflow-y properties.This is an example of one directional scrolling that uses the overflow-x and overflow-y properties.
</div>
Unfortunately the current CSS spec does not support these overflow-x and overflow-y properties - but W3C plan to include them in their next revision. In the meantime, they are still supported by all major browsers.
Currently the only valid way to use overflow is a general declaration: 'Overflow: value;'
You can assign four values to overflow and they should give the following results:
visible. the content flows out of the box.hidden. the overflowing content is completely hidden, not accessible to the user.auto. show scrollbars where necessary (horizontal or vertical or both).scroll. always show horizontal and vertical scrollbars, regardless of whether they're necessary. This value is never used; you generally want auto.Whatever your business needs, one of our highly trained small business development experts is sure to be able to help.
css, website design, scrollbars, overflow
Welcome to WebFertile. We'd love you to join us and benefit from:
View project briefs, client comments + latest Google® performance.
WebFertile
The Hive Business Centre
NTU Buildings
Burton Street
Nottingham
NG1 4BU
0115 849 2660
07973 122 619