html - Is position:absolute always counted from the top of the page? -


if make element inside , give properties position:absolute;top:10px; count 10px top of page , not inside .

is normal or should use instead position:relative; or something?

thanks answers!

absolute not related border of page. if take example:

<div class="box1" style="position:relative;">   <div class="box2" style="position:absolute;top:5;"></div> </div> 

the position of box2 dependent on position of box1.


Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

excel vba - VBA Proxy auto-configuration for http requests -

sql server 2008 - split ssrs expression between 2 words -