clear: both;
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns='http://www.w3.org/1999/xhtml' xml:lang='en'>
<head>
<title>peekaboo</title>
<style type='text/css'>
body {
font: 16px sans-serif;
}
div#container {
border: 1px solid rgb(200, 200, 200);
margin: 0 20px;
background: rgb(234, 234, 234);
padding: 5px;
}
a:hover {
background: crimson;
color: white;
}
div#float {
text-align: center;
float: left;
width: 150px;
height: 150px;
border: 1px solid rgb(200, 200, 200);
background: rgb(234, 234, 234);
}
div.content {
background: yellow;
border: 1px solid rgb(200, 200, 200);
}
div#clear {
border: 1px solid rgb(200, 200, 200);
background: orange;
clear: both;
}
</style>
</head>
<body>
<div id='container'>
<div id='float'>
Float text. <a href='#'>Link text</a>.
</div>
Content text. <a href='#'>Link text</a>.
<div class='content'>
Content text. <a href='#'>Link text</a>.
</div>
Content text. <a href='#'>Link text</a>.
<div class='content'>
Content text. <a href='#'>Link text</a>.
</div>
Content text. <a href='#'>Link text</a>.
<div class='content'>
Content text. <a href='#'>Link text</a>.
</div>
Content text. <a href='#'>Link text</a>.
<div id='clear'>
Clear text. <a href='#'>Link text</a>.
</div>
<div>
Another div.
</div>
</div>
</body>
</html>
Related examples in the same category