position:relative breaks out of overflow constraints

In any non-quirks mode doctype, content with position:relative within a block container with overflow: auto, scroll or hidden and a height shorter than its contents, will spill out past the bottom of the container.

Test page Workaround is not included
Reported by: Emmett Pickerel.

Explorer 5-6 Windows, Explorer 7 | Reported on 9 September 2005.

This site is no longer maintained. I’m sorry, but it’s just too much work for too little return. You can continue to browse old bug reports, though.

Search reports by browser:

Atom RSS


(Add your own)

1 Posted by Trevor Ochocki on 7 March 2006 | Permalink

I just wanted to mention that I have encountered this for the width as well.

2 Posted by Dusty on 9 August 2006 | Permalink

I believe I have discovered a workaround for this bug. IE will behave correctly if you add 'position:relative' to the containing element that is using 'overflow:auto'. I believe this is an expectable workaround because setting 'position:relative' without setting the 'top' or 'left' attributes will not affect the page layout.

See an example of the suggested workaround at my blog post on the subject.