margin is used for width and padding is used for height
Answers
Answered by
0
Answer:
Just place the div you want to give margins to inside of another div that has padding. Thus creating faux margins. Set the CSS box-sizing property to border-box to make width and height include the content, border, and padding. ... There is no way to include the margin itself in such a way.
Similar questions