Padding

The padding is the area between the content and the border. The single characteristic you can set for the padding element is size. The 5 width properties of padding are given below.

The possible values are:

ValuesDescription
padding-top
padding-right
padding-bottom
padding-left
padding

Then possible values for these properties are

ValuesDescription
<length>a fixed width. Only 0 or positive values are valid.
<percentage>specifies the width relative to parent element.
inheritthe property is inherited from the parent.
Padding shorthand
The padding property can accept up to 4 space delimited values.
For example
DeclarationDescription
padding : 1pxtop=right=bottom=left=1px
padding : 1px 2pxtop=right=1px, bottom=left=2px
padding : 1px 2px 3pxtop=1px, right=left=2px, bottom=3px
padding : 1px 2px 3px 4pxtop=1px, right=2px, left=3px, bottom=4px
Related Tutorial
Follow Us
https://www.facebook.com/Rookie-Nerd-638990322793530 https://twitter.com/RookieNerdTutor https://plus.google.com/b/117136517396468545840 #
Contents +