I have the following sample code:
<!DOCTYPE html>
<html>
<head>
<title>Example Website</title>
<link rel="stylesheet" type="css" href="style.css">
</head>
<body>
<div class="left_nav">1 2 3</div>
<div class="body_main">
<div class="top_nav_right">Create account Log in</div>
<div class="top_nav">
<span>Article Talk</span> <span class="top_nav_right2">Read
Edit View history</span>
</div>
</body>
</html>
and in my CSS:
.body_main {
margin-left: 11em;
}
.top_nav_right {
float: right;
margin-top: 1em;
margin-bottom: 1em;
}
.top_nav {
height: 2.5em;
margin-top: 3em;
}
.top_nav_right2 {
float: right;
}
I'm not sure why "Create account Log in" appears below "Read Edit View history". Those are both divs and I have the Read one following the Create one.
Also, for some reason, only Chrome displays the CSS. I have put the CSS in a validator