Share » Forums » Setup & design » 3.4 -> hummm, question about CSS. How...

3.4 -> hummm, question about CSS. How to set the topmargin="0"

3.4 -> hummm, question about CSS. How to set the topmargin="0"

Monday 26 July 2004 1:59:27 am - 4 replies

Author Message

Alex Jones

Monday 26 July 2004 6:06:00 am

Laurent, make sure that the top padding for body is also set to 0, in addition to setting your body margin to 0.

Also, so you know, you can reduce your code a bit, by changing your above code to:

div#allcontent
{
	width: 750px;
	margin: 0 auto;
}

You don't need to use the additional '0 auto' in your margin. This version will assume that you want both the top and bottom margins to be 0, while your left and right margins will be set to auto.

Hope this helps,

Alex

Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]

<i>When in doubt, clear the cache.</i>

laurent le cadet

Monday 26 July 2004 6:20:29 am

Hi Alex,

I tried what you said before to "have the chances to my side" but nothing...still a 10 px height topmargin...

I even removed completly the allcontent class.

Voodoo ?

Laurent

Mikhail Chekanov

Monday 26 July 2004 6:51:30 am

Try

body {
    margin: 0;
    padding: 0;
        ...
    }
div#allcontent {
    position: relative;
    width: 750px;
    margin: 0 auto;
    }

--
mike
#6595551

laurent le cadet

Monday 26 July 2004 7:09:32 am

Your are right Mikhail,

I forgot the "padding: 1em;" in the core.css (body).
Nearly everything is base on CSS now...lots of flexibility but so many class and style sheets.

Thanks for your help (both of U).

Laurent.

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu