I'm a software developer and I currently live and work in Nigeria. I write articles mainly targeted at Newbies in the tech field.
I also write about what I'm learning and building on this blog—most of them about programming, technology and documentation.
Markdown supported · ⌘↵ to post
Joe Attardi
The section on
position: absoluteis not quite accurate - the element is not necessarily positioned relative to its parent container.An absolutely positioned element is positioned relative to the nearest ancestor (not necessarily direct parent) that has a
positionother thanstatic. Sometimes it can get a little tricky.To make an absolutely positioned element relative to its containing element, you can just set
position: relativeon the parent.