0

I am building a new page and I'm having problem having this space on top of it.

you can take a look at it http://www.mtimexico.com.mx/graficos.php

here's the situation. All Divs are inside a Parent Div called Container. This div has the following qualities:

body {
    margin-top: 0; 
    padding-top: 0; 
    background-image: url(images/bg.gif); 
    background-repeat: repeat-x; 
    background-attachment: fixed; 
    background-color:#003366; 
    font-family:Arial, Helvetica, sans-serif;
    }

#container {
    position:relative;
    width:1000px; 
    height: 1250px; 
    top: 0;
    margin-left: auto; 
    margin-right: auto;
    margin-top: 0;
    border: 1px black solid;  
    z-index: 3;
    }

If I remove the container Div and just have the child Divs then the space on top disappears and the page goes to the top, however it gets aligned to the left.

As you can imagine what I want is the page both centered and on top, so I'm pretty much working with the files that have the container, so that's why I'm trying to fix either

http://www.mtimexico.com.mx/graficos.php or

http://www.mtimexico.com.mx/menu-soporte.php

I'm assuming there is an issue with the CSS of the menu, because it's the only rare addition apart from the normal CSS.

I've been working on this all day long but can't figure out a solution, if you can please help me out.

Edited by mike_2000_17: Fixed formatting

3
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by gaurang4
0

Y'see, I was all "I've got the solution" after I fixed something similar on my own page but then I looked at your snippets again and saw that your body class already has margin-top: 0;

What I might recommend, however, is to check your page conainer by container (body, divs, etc) and ensure that the top 2 containers of your page have 0 top margins either through CSS or via topmargin="0" as that was the only thing in my site that was causing any downward shift of the top area of my page.

0

Right Lusiphur.

You may also,
add this in css
*
{
margin:0px;
paddin:0px;
}
Then adjust margin padding of each individual elements separately, it would also help to get all browser compatibility.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.