What is the default value for the "position" attribute?

5

In CSS, I know that the position property can receive the fixed , absolute and relative values. Each has a different effect on the position of the element.

But I was in doubt when I was asked the following way by another programmer:

"If I have an element with fixed , absolute or relative and want to reset to the value that comes by default in CSS, what would be the value of I have to set position ? ".

So I would like to ask this question: What is the default value of the property position ?

    
asked by anonymous 22.11.2016 / 20:50

2 answers

10

The default value is static for any HTML element that does not have position specified

position: static;

As explained in link

    
22.11.2016 / 20:52
6

The default value is static .

It is referenced in MDN and W3C :

  

position
Value: static | relative | absolute | fixed | inherit
Initial: static

    
22.11.2016 / 20:53