Previous Message
Next Message

Bug or standards compliant? Applied margins to an inner div cause outer div to weirdly collapse if it has no borders.

Sent by Sascha Ebach on 13 October 2005 22:10


Dear list,

I have been working around this behaviour (bug?) for quite some time 
now. I can't take it anymore :) Let me explain. Or better yet give you a 
barebones example. Please have a look at the fully commented testcase I 
have here:

http://www.digitale-wertschoepfung.de/test/margin-kills-background.html

I hope you can understand what my problem is here. Now, is this the 
expected behaviour for standard compliant modern browsers? Where is it 
documented? (I wouldn't know how to search for this problem). Do I have 
to use borders at all cost? I don't want to use position: absolute or 
fixed dimensions either. And naturally I want to avoid padding on the 
outer div as well. I have worked around this for at least 15 in the last 
times year by simply applying borders, but I want to finally understand 
what is going on here.

-- 
Sascha Ebach
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Message thread: