Skip to main content


Showing posts from November, 2014

CSS relative absolute positioning

Over my course of being a frontend web programmer, I realised that a lot of web developers dont understand how css position works. If you're a new web developer, after mobile webkit, firefox or chrome became bigger than IE, then everything is way easier to understand. The most simple explanation is this Basically if the position is static(default), the children with different position (relative, absolute) will follow the first non static position parent it has (which on the site was the body).
So for example <body> <div style="position:absolute;top:10px"> this div parent(body) is static so make that our bounds </div> </body> <body> <div> <div style="position:absolute;top:10px"> this div parent(div) is static and so its parent(body) so make body our bounds </div> </div> </body>…