I want a few divs to be positioned in a line next to each other, but also allow them to overlap the previous div.
What I\'m trying to get is a timeline with divs for
It's simple. Make an inner div using absolute positioning but wrapped with a div that uses relative positioning:
a
You can use another method like negative margin, but it's not recommended if you want to dynamically change HTML. For example, if you want to move the position of the inner div(s), just set the top/left/right/bottom CSS properties of the container or modify the properties using JavaScript (jQuery or otherwise).
It will keep your code clean and readable.