A block level element may be made to appear as if it is inline if floated:
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
.floater {
width:8em;
height:2.5em;
float:left;
margin-right:1.5em;
border:1px solid #cccccc;
}
</style>
</head>
<body>
<div><div class="floater">some content that can wrap once</div>
<div class="floater">some content that can wrap once</div>
<div class="floater">some content that can wrap once</div>
<div class="floater">some content that can wrap once</div>
<div class="floater">some content that can wrap once</div>
<div style="clear:left;"></div></div>
</body>
</html>
Bookmarks