Forum Moderators: open

Message Too Old, No Replies

Netscape problems

How can I set the bottom margin of pages to Zero in Netscape?

         

Canton

4:20 am on Mar 11, 2002 (gmt 0)

10+ Year Member



This may be an elementary question, but here goes anyway: I've set up my pages so that they spread out over the height of the browser, regardless of setting (100% Height setting for the main table). However, in Netscape, on pages with less content that don't push down past the set Height of the user's computer/monitor, there is always a gap at the bottom of the page. Any idea of how to fix this? The bigger problem is that my background is showing through where I don't want it to, underneath my main table at the bottom of the page.

Thanks in advance to anyone with advice.

~Canton

tedster

4:40 am on Mar 11, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Using percentages for a height attribute (whether div height or table height) won't give dependable cross-browser results. The best way I know to do it is a bit complex. First use Javascript to get the window height. Then write the table or div to that height in pixels.

Then to make Netscape behave, you need to give the table some content that fills it to that dimension (a transparent gif image can do the trick.) Otherwise, Netscape won't grab anymore screen real estate than the content requires, no matter what attributes you write.

If you do a site search here on phrases like "div height" "table height" "css height" etc you will find many posts that struggle with similar issues and links to references as well.

All this is rather messy (and needs to be re-triggered if the window is resized). So many people chose to re-think the design. Depending on the background (which you say is the major issue for you), you might prefer to come up with another way of creating the effect you want, such as a CSS no-repeat.

pageoneresults

4:52 am on Mar 11, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Depending on the background (which you say is the major issue for you), you might prefer to come up with another way of creating the effect you want, such as a CSS no-repeat.

That's what I had to do. We just changed the backgrounds around and solved the problem. Any background images that have height should be set as background images with the CSS no-repeat as mentioned above. Any background images that have width's are easily controlled.

Tedster's javascript suggestion is probably the best alternative.

If you do a site search here on phrases like "div height" "table height" "css height" etc.

Do a search in Google for those terms and you won't find much. Why? Because you can't do it, bummer!

mivox

6:39 am on Mar 11, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Don't sweat the finer details in Netscape... If the worst Netscape display problem you have is a little white space at the bottom of the screen, count yourself lucky!

Reflect

1:48 pm on Mar 11, 2002 (gmt 0)

10+ Year Member



Hi,

I always throw this in the <body> tag...

leftmargin="0" topmargin="0" marginwidth="0" marginheight="0"

This gets the page hitting all borders top, botrtom, left and right.

Brian

Canton

3:55 pm on Mar 11, 2002 (gmt 0)

10+ Year Member



Thanks everyone...I've now got some info. to overcome/conquer Netscape if I want...Mivox, I like your advice too, since Netscape users are certainly in the minority and the site looks beautiful in MSIE.

mivox

6:19 pm on Mar 11, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I'm not saying ignore Netscape entirely, because I've found a lot of sites which simply don't function in Netscape because the webmaster was lazy with the table closing tags, or picked an incompatible Javascript, etc... But as far as minor visual problems, as long as the site looks decent and functions properly, it's nothing I'd worry about.