inline divs with hidden overflow

Posted by Jim on Stack Overflow See other posts from Stack Overflow or by Jim
Published on 2011-01-16T12:27:57Z Indexed on 2011/01/16 13:53 UTC
Read the original article Hit count: 335

Filed under:
|
|
|
|

I want to create 3 divs side by side when only one of them is visible.

-------------- -------------- --------------
| visible    | | invisible  | | invisible  |
|            | |            | |            |
-------------- -------------- --------------

In order to do this I have tried to create a wrapping div with a 100px width, and hidden overflow. What am I doing wrong?

<div style="width:50px;height:349px; overflow:hidden">
<div style="display: inline;">first div</div>
<div style="display: inline;">second div</div>
<div style="display: inline;">third div</div>
</div>

© Stack Overflow or respective owner

Related posts about css

Related posts about div