Latest

recent

CSS padding-top Property

Definition

The padding-top property sets the top padding (space) of an element.
Note: Negative values are not allowed.
Inherited: No

JavaScript Syntax

CSS properties can also be dynamically changed with a JavaScript.
Scripting Syntax: object.style.paddingTop="2cm"

Example

h1
{
padding-top: 10px
}

Possible Values

Value Description
length Defines a fixed top padding. Default value is 0
% Defines a top padding in % of the height of the closest element. This value does not work like expected in all browser

Goto CSS3 and CSS2 complete reference
CSS padding-top Property Reviewed by 1000sourcecodes on 21:07 Rating: 5
Powered by Blogger.