Source code

Revision control

Copy as Markdown

Other Tools

<!doctype html>
<meta charset="utf-8">
<title>CSS Test Reference</title>
<style>
#container {
width: 400px;
height: 400px;
margin: 100px;
background-color: purple;
position: relative;
}
#spacer {
height: 300px;
}
#bottom {
height: 100px;
background-color: green;
}
#abspos {
position: absolute;
width: 100px;
height: 100px;
background-color: green;
top: 0;
left: 0;
}
</style>
<div id="container">
<div id="spacer"></div>
<div id="bottom"></div>
<div id="abspos"></div>
</div>