Firstly, simplify your CSS:
Code:
.search {
border:1px solid #8CACBB;
background-color:#DEE7EC;
color:#000;
line-height:1.6em;
margin:0;
padding:5px 1px 0 1px;
}
Second, add clear:both to the container of the "Advanced Search" and add the clear:both div after it, not before.
Code:
<div style="font-size:8pt; float:right; clear:both;">
<div>Advanced search</div>
</div>
<div style="clear:both"></div>
You did say this was a "simplified" version of your markup, so I won't make too much of a judgment. However, it seems to me that you're a bit "over-divifying" here. You could accomplish the same thing which much less markup. Like so:
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN
"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Search</title>
<style type="text/css">
.search {
border:1px solid #8CACBB;
background-color:#DEE7EC;
color:#000;
line-height:1.6em;
margin:0;
padding:5px 1px 0 1px;
text-align:right;
}
.search a {
display:block;
font-size:8pt;
}
</style>
</head>
<body>
top
<!-- begin simple search -->
<div id="simpleSearch" class='search'>
<input id="search" type="text" value="search">
<img src="xmag-22.png" onclick="alert('perform simple search');"/>
<a href="#">Advanced search</a>
</div>
bottom
</body>
</html>
Bookmarks