Contact Us || Privacy Policy || About Us |
|
CSS PositionThe position property specifies the type of positioning method used for an element. There are 5 different position values that is:
It always used to 4 coordinates properties that is :
1) CSS Position: staticThe static position always positioned according to the normal flow of the page: It is also knon as default position value. Example Test it Now2) CSS Position: relativeIf the position is set to relative, an element can move according to its current position. Example Test it Now3) CSS Position: fixedYou can set left/right & top/bottom coordinates. If the position is set to fixed. Example 1 Test it NowFixed Top Menu ExampleTest it Now4) CSS position: absoluteThe absolute position: is used to relative to the nearest positioned ancestor (instead of positioned relative to the viewport, like fixed). Example Test it Now5) CSS Position: stickyThe sticky position is used to scroll position. Example Test it Now
Next Topic CSS Overflow (Layout)
|