Question about creating a page for beginners:
I have a simple / div container defined using a CSS style called content_bottom:
border-top: 5pt solid
When I start typing, I notice that the text starts touching the very left edge of the window. I tried to add padding and even borders to the container (via CSS style), but there was no effect. However, adding upper / lower DID borders has an effect. Why is this? What should I do to prevent the text from touching the left (and top) window? Thanks.
PS This is the full HTML for the page:
<html> <head> <meta content="text/html; charset=UTF-8" http-equiv="content-type"> <title>site title goes here</title> <link rel="stylesheet" href="penonek.css" type="text/css"> </head> <body> <div class="wrapper"> <div class="column_top">this <br> </div> <div class="content_top">is site title<br> </div> <div class="column_bottom"> <ul> <li>home</li> <li><a href="#">link 1</a></li> <li><a href="#">link 2</a></li> <li><a href="#">link 3<br> </a></li> </ul> </div> <div class="content_bottom">this is the container content<br> </div> </div> </body> </html>
Here is the full CSS:
body { margin: 0; padding: 0; text-align: center; background-color: black; font-family: Arial,Helvetica,sans-serif; color: #cccccc; font-size: 16pt; } .wrapper { margin: auto; min-width: 900pt; font-family: Arial,Helvetica,sans-serif; width: 900pt; color: #cccccc; } .column_top { border-width: 0 0 5pt; border-bottom: 5pt solid black; min-width: 150pt; color: #333333; width: 150pt; max-width: 150pt; background-color: #f4f4f4; float: left; min-height: 45pt; max-height: 45pt; height: 45pt; padding-top: 105pt; font-size: 40pt; text-align: right; font-weight: bold; } .content_top { border-width: 0 0 5pt; border-bottom: 5pt solid #f4f4f4; height: 45pt; min-height: 45pt; max-height: 45pt; padding-top: 105pt; text-align: left; font-size: 40pt; font-weight: bold; } .column_bottom { border-width: 5pt 0 0; border-top: 5pt solid black; color: #333333; background-color: #f4f4f4; width: 145pt; min-width: 145pt; max-width: 145pt; text-align: right; padding-top: 50pt; padding-right: 5pt; float: left; } .content_bottom { border-top: 5pt solid #f4f4f4; padding: 10pt; border-collapse: separate; text-align: left; } .column_bottom ul { margin: 0; padding: 0; font-weight: inherit; color: #333333; list-style-type: none; text-decoration: none; } .column_bottom a:hover { background-color: #999999; } .column_bottom a { text-decoration: none; font-weight: inherit; color: #333333; }
source share