On 8/24/05, Bruce Gilbert <[EMAIL PROTECTED]> wrote: > On this site :http://www.semlogic.com/ > > there is some unwanted spacing on the right margin where my h2 is for > testimonials is. (between the header and top gray bar). I am not sure > where this is coming from. Can someone take a look and give me some > possible suggestions?
Hi, Bruce, This is vertical margin collapsing, rearing its confusing head. :-) Basically, vertical margins collapse/merge between/around elements whenever there is no padding or border between them. In this case, the culprit is the .5em top margin on #centre. If you replace this top margin with top padding, you'll get the effect you were looking for. Why this happens is pretty complex. It's been discussed a few times before on the list; check the following links for further discussion on collapsing margins: Me on collapsing margins: http://archivist.incutio.com/viewlist/css-discuss/51839 The specification: http://www.w3.org/TR/REC-CSS2/box.html#collapsing-margins Eric Meyer on why collapsing margins exist: http://archivist.incutio.com/viewlist/css-discuss/33569 HTH, Michael ______________________________________________________________________ css-discuss [EMAIL PROTECTED] 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/
