CSS position Property
To specify the positioning scheme to be used layout the element.
Definition and Notes.
1. The CSS position property enables you to define what type of positioning method is used by a browser when the element is laid out on the webpage.
2. Any element can be positioned, but an element positioned with absolute or fixed values will generate a block level box regardless of what type of element it is.
CSS position property.
View in Splitscreen»
Code-Editor:Note-The fixed element never moves w.r.t to the browser's viewport and occupies no space within the parent element
|absolute||The element is positioned relative to its first ancestor that has a position value other than static.|
|fixed||Similar to absolute, but the element is positioned w.r.t to the browser's viewport|
|relative||The element is positioned relative to its normal position within the document flow, the position of other elements remains unaffected|
|static||The element is left in its normal position.Its the default|
|inherit||The value of positioning property is inherited from the parent element|
|Value||static | relative | absolute | fixed | inherit|
|Applies to||All Elements|
|Computed Value||Same as declared value.|