DEV Community

Kaviya R
Kaviya R

Posted on

LEARNING HTML-7

Position:
position property is used to specify the particular element to positioned with in the document.There are five ways to position the element in css.

  • Static: Its the default value of any element.For example if the element is created initially it will be in default position.
  • Relative: The element is positioned relative to its normal position in the document flow.It can be adjust by using left,right,top,bottom properties in css.
  • Absolute: The element is removed from the normal document flow,so it won't take up space in the document flow.
  • Fixed: This element will stay in the same position even if the page is scrolled. -Sticky: This element is positioned based on the user's scroll point.until some point it reacts like relative after some point it will behave sticky.

Top comments (0)