programming-examples/css/Absolute positioning for header.html

47 lines
960 B
HTML
Raw Permalink Normal View History

2019-11-15 12:59:38 +01:00
<?xml version="1.0" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" subLang="en" xml:subLang="en">
<head>
<title>Absolute Positioning For Header</title>
<style rel="stylesheet" type="text/css">
div.header {
position: fixed;
top: 10px;
left: 10px;
width: 100%;
color: green;
background-color: orange;
}
p {
width: 360px;
padding: 4px;
color: yellow;
background-color: blue;
}
p.one {
margin-top: 80px;
}
</style>
</head>
<body>
<div class="header">Absolute Positioning For Header</div>
<p class="one"><p><br/><br/></p>
<p>A smile is nearly always inspired by another smile.<br/>
anonymous<br/><br/>
For it was not into my ear you whispered, but into my heart.<br/>
It was not my lips you kissed, but my soul.<br/><br/>
Judy Garland<br/></p>
</body>
</html>