<!DOCTYPE html> | |
<!-- | |
| Absolutely positioned elements should be positionable by specifying left | |
| as a length. | |
--> | |
<html> | |
<head> | |
<style> | |
.container { | |
position: absolute; | |
width: 300px; | |
height: 300px; | |
background-color: rgb(255, 100, 100); | |
} | |
.block { | |
position: absolute; | |
width: 50px; | |
height: 50px; | |
left: 150px; | |
background-color: rgb(100, 100, 255); | |
} | |
</style> | |
</head> | |
<body> | |
<div class="container"> | |
<div class="block"></div> | |
</div> | |
</body> | |
</html> |