CSS Positioning
CSS positioning is used to position an element on the web page.It has different positioning method that is used by element during positioning in the web page.These positioning methods are static
, relative
, fixed
, absolute
or sticky
.
CSS Positioning Property
Followings are the positioning properties.
static
relative
fixed
absolute
sticky
CSS Static Positioning
This is the default positioning of the HTML element and it is not affected by the top, bottom, left, right, and z-index properties. It always positioned as per the normal flow of text.
Statement
.box{ padding: 20px;background: #7dc765;}
The CSS position property is used to place the element left,right,top,bottom from its normal position.