Click to See Complete Forum and Search --> : Empty space at top of page
lindsayanng
05-22-2008, 06:14 PM
I have this WEIRD and VERY random empty space at the very top of my website. Every page has the same issue too, i am wondering if it is something to do with my template, but I am not sure. HOPEFULLY someone can look at the page and tell me what is causing this
www.bscphoto.com
I have the page margins all set to 0 and there is NO border on the banner or around the background. Can someone PLEASE help>
Centauri
05-22-2008, 10:32 PM
Maybe starting the pages with a valid doctype may help.
jonod1
05-23-2008, 06:27 AM
Hmm, you do have a lot of random code and errors such as your </br> or line break tags which should be <br />.
However, it looks like the table which is causing the problem, so i would try taking out the banner image and placing it just under the <body> tag in its own div such as:
<body>
<div align="center"><a href="index.html"><img src="bscphotography.jpg"></a></div>
Perhaps give that a try first, otherwise its a problem with your table.
Cheers
tasneem
05-29-2008, 04:49 PM
hi
try setting body top margin=0 in css.
thanks
Ves_Paul
06-05-2008, 09:55 AM
I have this issue as well, even on the pages with the most basic code. It seems like every site I build in Dreamweaver won't truly align to the top of the page without a thin margin. Following are some samples:
http://www.davidcarpenterinteriors.com/temp/index.htm
http://www.artsfifthavenue.com/
I'm thinking (hoping) there is some uncomplicated fix for this.
Thanks.
Centauri
06-05-2008, 10:59 AM
Giving the body zero margins works with both those sites, and they could both do with valid doctypes and rewriting with semantic code.
Ves_Paul
06-05-2008, 12:03 PM
Giving the body zero margins works with both those sites, and they could both do with valid doctypes and rewriting with semantic code.
Please forgive my hackness, but can you describe the look of the code to accomplish zero margins? Also, in what way is the doctype invalid?
Thanks for your time.
-P
Ves_Paul
06-05-2008, 12:16 PM
Actually just got it right like this; " <body bgcolor="#000000" link="0" vlink="#000000" alink="#660000" marginheight="0"> "
I just added marginheight="0" in the body. Thanks, Cent.
Centauri
06-05-2008, 06:56 PM
For the doctype to be valid (and therefore work in IE) it needs to have the uri section as well. A complete html 4.01 transitional doctype looks like <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
The styling of the page elements should be done in css - those html styles are deprecated. The body and link styling can be done via a styling section in the page <head> :<style type="text/css">
body {
margin: 0;
padding: 0;
background-color: #000000;
}
a {
color: #000000;
}
a:hover {
color: #660000;
}
</style>