473,382 Members | 1,332 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

Netscape margin attributes

I have been writing web pages for years using these attributes to the
body tag:

<body bgcolor=#FFFFFF marginwidth=0 leftmargin=0 marginheight=0
topmargin=0>

I'm now attempting to bring my pages into compliancy with the latest
css based standards. I have removed the bgcolor, leftmargin, and
topmargin attributes in favor of style sheet properties:

BODY {background: #FFFFFF; margin-top: 0px; margin-left: 0px;}

but, what do I do with the Netscape-specific attributes marginwidth and
marginheight? If these are not set somewhere my pages show a small
white margin on the left and top when viewed in Netscape, Mozilla, etc.

- Bob

Jun 2 '06 #1
2 2220
silverbob <bs**********@symark.com> scripsit:
I have been writing web pages for years using these attributes to the
body tag:

<body bgcolor=#FFFFFF marginwidth=0 leftmargin=0 marginheight=0
topmargin=0>
It has always been wrong. The bgcolor attribute's value is malformed (the
syntax requires quotation marks around it), and the other attributes are
proprietary, nonstandard. Besides, setting background color without setting
text and link colors has always been bad practice.
I'm now attempting to bring my pages into compliancy with the latest
css based standards. I have removed the bgcolor, leftmargin, and
topmargin attributes in favor of style sheet properties:

BODY {background: #FFFFFF; margin-top: 0px; margin-left: 0px;}
That's not quite the same thing.
but, what do I do with the Netscape-specific attributes marginwidth
and marginheight? If these are not set somewhere my pages show a
small white margin on the left and top when viewed in Netscape,
Mozilla, etc.


To remove all margin-like things, set
html, body { margin: 0; padding: 0; }
This is normally not a good idea, though. Margins are generally useful. The
default margins should be increased a little rather than removed.

--
Yucca, http://www.cs.tut.fi/~jkorpela/

Jun 2 '06 #2

silverbob wrote:
I have been writing web pages for years using these attributes to the
body tag:

<body bgcolor=#FFFFFF marginwidth=0 leftmargin=0 marginheight=0
topmargin=0>

I'm now attempting to bring my pages into compliancy with the latest
css based standards. I have removed the bgcolor, leftmargin, and
topmargin attributes in favor of style sheet properties:

BODY {background: #FFFFFF; margin-top: 0px; margin-left: 0px;}

but, what do I do with the Netscape-specific attributes marginwidth and
marginheight? If these are not set somewhere my pages show a small
white margin on the left and top when viewed in Netscape, Mozilla, etc.

- Bob

Do it this way.

<style type="text/css">
body {
margin:0;
}
</style>

Leave the body tag empty. Everything you can do in there can be done
better with style sheets.

<body>

best html reference http://www.w3schools.com/html/html_reference.asp
best style sheet reference
http://www.w3schools.com/css/css_reference.asp html links
http://www.websitetips.com/html/ style sheet links
http://www.websitetips.com/css/ html dom
http://www.w3schools.com/htmldom/dom_reference.asp

Jun 5 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Csaba2000 | last post by:
I apologize for the length of the page below, but I've tried to whittle it down as much as I can. The problem is that Netscape 6.1 on my Win 2K Pro machine is disappearing the final row of the...
9
by: Sector024 Media | last post by:
My question is why netscape doesn't seem to support a style definition in a table? I have my pages as valid xhtml1.0, and still netscape is not folowing orders.. <table...
6
by: Nicolai P. Zwar | last post by:
Hi there, everybody. This here is a sample page of what appears to be a Netscape/Mozilla positioning problem. I posted a the problematic code down at the bottom of this message, and you can see...
7
by: Jonas Smithson | last post by:
Hello all, I have an absolute positioned parent div, and nested inside it is an absolute positioned child div -- I mean the div *code* is nested inside, but the child is physically positioned so...
3
by: Mr. T. | last post by:
Hello, i have a page where i have a white box centered on the screen. Now in IE everything shows fine, but in FireFox and Netscape the background of the box isn't white. But all the positioning...
2
by: Norman Swartz | last post by:
OS system is Windows XP Pro SP2. The following works perfectly in IE but not at all in Netscape: <tr> <td valign="middle" background="dull.gif" onMouseOver="this.background='bright.gif';"...
6
by: qqq | last post by:
I'm a relative newbie... I'd like my site to support Netscape browsers. For a page I set 'TargetSchema' to 'IE 3.02/Netscape 3'. When I insert label or textbox web controls on the page, they...
2
by: Victor | last post by:
Hi I have a very strange problem for my page. I have writen a js to make sure my table's height is 100% for the browser's viewport. my code is just the following. This works fine for firefox and...
3
by: J055 | last post by:
Hi I want to add some css rules to the this.Header.StyleSheet property. I need to add margin and some other css properties but the Style class doesn't support them. What is the best way or some...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.