Position: Absolute

// Apr 23, 2015

So I’ve been using position: absolute; for about as long as I can rememeber, but today I can say I fully fully understand it. Here’s the golden rule:


position: absolute; will position itself relative to the FIRST parent element that is NOT position: static;

This is very important because by default elements are going to be position: static;. Therefore if you want to position divs absolutely inside other divs, MAKE SURE those parent divs have their positions defined as anything besides static!



YES I FINALLY GOT IT. THIS IS THE BEST FEELING EVER.

(Thanks to Murat)