absolute positioned element clipping if position outside its parent item IE7

Posted by yazz on Stack Overflow See other posts from Stack Overflow or by yazz
Published on 2010-05-21T07:45:49Z Indexed on 2010/05/21 7:50 UTC
Read the original article Hit count: 207

Filed under:
|
|
|

Hi

Im trying to position an element so its slightly positioned outside its parent item. In IE8 it works but in IE7 the positioned element gets clipped.

Here's my code HTML:

<div id="parent">
    <div id="child">text</div>
</div>

The CSS

#parent {
height: 40px;
width: 400px;
position: relative;
}

#child {
position: absolute;
width: 100px;
height: 60px;
top: 0px;
left: 0px;
}

In IE7 you will see that the last 20px of the child element gets clipped. How can I solve this?

THX

© Stack Overflow or respective owner

Related posts about html

Related posts about css