padding

Specifies the amount of padding space between the content of an element and its border.

Platform Support

IENetscapeMozillaOperaSafari
4.0+4.0+1.0+4.0+1.0+

Usage

[top] [right] [bottom] [left]

Example

To specify a padding that is 10px wide on the top and left and 5px wide on the bottom and right, use the following syntax: body {padding: 10px 5px 5px 10px;}.

Remarks

Use the padding property as a shortcut to typing out all of the individual padding properties separately. You can specify any valid value for a padding property as part of padding.

You can specify up to four different widths for the amound of padding for an element.

Availability

W3C CSS2

Related

text_css aptana_docs