Hi.
A section of the page I'm developing has a table within a fixed size div. The table fits the contatiner height, but is much wider, so I want horisontal scrolling.
However, the design doesn't look good with the vertical scrollbar present, even if it is shaded out as inactive. To solve this I used this css script :
overflow-y:hidden;overflow-x:auto;
...which works perfectly, but of course only in IE.
Is there a way to achive this in gecko (NN, Moz) and Opera as well ?
If not, is it possible to keep this feature in IE and have scrolling both vertical and horizontal in the other browsers without having to detect the browser with javascript and use different stylesheets ?
All help will be greatly appreciated : )
Eirik, Norway
Horizontal scrollbar only : Works in IE but nothing else...
Hi waybck,
With overflow-x and y are IE only.
By default other overflow is set to visible, change this to auto then browsers should only use them when needed.
Then after that statement use overflow-y:hidden;overflow-x:auto; for IE and you should get close to what your after.
Hope that helps
Horizontal scrollbar only : Works in IE but nothing else...
thanks fro the tip. didn't work though...
I fixed it with a css-hack that is used for hiding css on IE. Then I applied overflow:auto on just Opera, mozilla and NN.
the hack :
<style type="text/css">
div[id] {
overflow:scroll;
height:148px;
}
</style>
the div :
<div STYLE="overflow-y:hidden;overflow-x:auto;width:100%;" id="idSelector">
.....