Reputation: 1
I'd like to keep a div (a CSS3 box) to a certain width. But somehow, overflow:hidden and max-width seem to be ignored.
<html>
<head></head>
<body>
<div style="display:-moz-box;">
<!-- Keep the red div 100 px wide, regardless of its content. But how? -->
<div style="background-color:red; padding:2px; width:100px; max-width:100px; overflow:hidden;">
<div style="width:500px; border: 1px solid yellow;"> </div>
</div>
<div>2</div>
</div>
</body>
</html>
Currently testing in Firefox 6.
Upvotes: 0
Views: 731