Contents

position

The position property specifies the positioning algorithms for elements.

Description

Values

static | relative | absolute | fixed | inherit

Initial value

static

Applies to

All elements

Inherited

No

Values

staticThe box is a normal box, laid out according to the normal flow. The 'top', 'right', 'bottom', and 'left' properties do not apply.

relativeThe box's position is calculated according to the normal flow. Plus, the 'top', 'right', 'bottom', and 'left' properties apply.

absoluteThe box is taken out of the normal flow. The box's position (and possibly size) is specified with the 'top', 'right', 'bottom', and 'left' properties.

fixedAccording to the 'absolute' model, the box is taken out of the normal flow but does not move when scrolled. The box's position is specified with the 'top', 'right', 'bottom', and 'left' properties.

inheritTakes the same specified value as the property for the element's parent.