PDA

View Full Version : margin="0"


pilsjart
04-20-2003, 11:57 AM
hello.

well I have these pages were I put:

<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">

a table with no specification on WIDTH , nor HEIGHT (not in TABLE, TD, nor TR) The cells of the table only contain some pictures. all organized so the all table form a "big picture" (<table border="0" cellspacing="0" cellpadding="0">).

some pictures have maps asociated with them. and there is nothing else, and still I get a small space at the bottom of the widow and at the right (the window size is adjusted to the "big picture" size) so I get scrollbars.

But, when I refresh (F5) the page, spaces on bottom and on right disappear, getting wat I wanted.

How can I get rid of the margins or spaces I get on the bottom and on the right of the window?

thanks

Mhtml
04-20-2003, 12:50 PM
AAARRRGGHHH!!!

lol, sorry .. Um well have you looked into CSS? That's what you should be using.

body {
margin:0px;
}


Get's rid of margins on all sides.

Http://www.w3schools.com/css - Consult w3 schools for more information on css.

[edit:] The arrrggghhh! was because topmargin="0" etc is bad, very very bad! Well it works but it's no longer in the standard.

redhead
04-20-2003, 01:33 PM
you need to do padding for some browsers too, so try this:

body {
margin: 0px;
padding: 0px;
}

:thumbsup: