Forum Moderators: not2easy
I have set up a lightbox on my site, however when it loads, it darkens the HTML tag portion of the site, so far so good.
The problem however is that in Safari and Firefox, my HTML tag is centred and has a fixed width.
In IE the HTML tag is shoved to the left side.
So when the lightbox loads in IE, the dark background doesn't look good, this is what I have in my CSS file:
body {
background-color:#121e2f;
margin:0px auto;
width:1059px;
font-family: "Lucida Grande", "Lucida Sans", "Lucida Sans Unicode", "Lucida", Verdana, "Bitstream Vera Sans", sans-serif;
text-align:center;
}
#bodywrapper {
width:1059px;
text-align:left;
}
Any tips appreciated.
You shouldn’t be trying to position the body the way you are because your #bodywrapper should be doing it. Strip out the widths and margins from the body and add them to the wrapper. That will then centre all content inside the wrapper.
The <html> tag should the second tag on the page (below doc type) and the very last closing tag at the bottom of the page. Anywhere else and you will have problems.