Easy Tutorial
❮ Event Onmouseenter Prop Img Complete ❯

paddingBottom Property


Definition and Usage

The paddingBottom property sets or returns the bottom padding of an element.

Syntax

Set the paddingBottom property:

Return the paddingBottom property:

Value Description
% Defines the bottom padding as a percentage of the width of the parent element.
length Defines the width of the bottom padding using units like px, cm, etc.
inherit The bottom padding is inherited from the parent element.

Browser Support

All major browsers support the paddingBottom property.

Note: IE7 and earlier versions do not support the "inherit" value. IE8 requires a !DOCTYPE to support "inherit". IE9 supports "inherit".


Tips and Notes

Both the margin and padding properties insert space around an element. However, the difference is that margin inserts space outside the border, while padding inserts space inside the border.


Example

Change the bottom padding of a div element:

❮ Event Onmouseenter Prop Img Complete ❯