DarkxPunk Posted January 20, 2013 Share Posted January 20, 2013 (edited) Hey everyone so I have two pictures Box model ideal:Box model real:As far as I understand box model the ideal should happen, but the real happens... Why? Anyway around it? BLAH! I know you can use padding, but it does not make sense Thanks for any help. -EDIT- Gotta set the wrapper to overflow anything other than visible. Still silly. Stupid collapsing. Edited January 20, 2013 by DarkxPunk Link to comment Share on other sites More sharing options...
Ingolme Posted January 20, 2013 Share Posted January 20, 2013 It's called collapsing margins. vertical margin of an element will be applied to the ancestor. The easiest way to solve it is to add overflow: hidden to the container. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now