0

What is difference between padding and margin ?

Let me help to understand the padding and margin

6th Mar 2021, 2:21 AM
Avinash Kumar
Avinash Kumar - avatar
4 Respuestas
+ 2
an html element is a block of text, with internal spacing (padding: inner margin, from border to text) and external spacing (margin: outer spacing around borders)
6th Mar 2021, 2:26 AM
visph
visph - avatar
+ 2
Padding is distance of inner text or elements from the wall of container And margin is the distance of container from its parent element
6th Mar 2021, 2:30 AM
Ayush Kumar
Ayush Kumar - avatar
+ 2
Ok got it, visph and 丹ⓨㄩک廾 , thank you very much bro
6th Mar 2021, 2:31 AM
Avinash Kumar
Avinash Kumar - avatar