Dumb CSS Questions
Dumb CSS Questions
Out of context: Reply #4
- Started
- Last post
- 13 Responses
- orrinward20
Paddings, border and margins are added after by default.
Box-sizing specification works too if you don't care for older browsers.
Xophers snippet means width is inclusive of Border and Padding, but not margin.
Margin should never be included in a specified width as margins are... permeable? Something with margin-right:20px next to something with margin-left:10px will mean they have 20px space between them. Wanting margins to behave like padding is misuse.
- padding is inside the box, marign is outside so not part of the width - its quite simplefadein11