I am trying to update my old website from tables to only CSS using DIV tags, I have tried various coding, and this one is the closest, but my left and right columns disappear to the bottom somewhere. Here is the CSS Code I used. Can anyone let me know where I am going wrong? I want the website to look like my old one http://www.i4-webdesign.com which has a 2px border, when I omit the border it looks fine. Also I require it to be 900px wide. Thank you.
body {
margin:0;
padding:0;
line-height: 1.1em;
background-color: #fff;
}
#container {
width: 900px; /*Width of main container*/
margin: 0 auto;
background: #FFF;
}
#wrapper1 {
position:relative;
width:900px;
background:#FFF;
}
#wrapper2 {
position:relative;
text-align:left;
width:900px;
background: #FFF;
}
#header {
background: #FFF;
height: 200px; /*Height of top section*/
margin: 0;
padding-top: 0px;
}
#maincol {
margin: 0 225px 0 185px; /*Margins for content column. Should be "0 RightColumnWidth 0 LeftColumnWidth*/
}
#leftcol {
float: left;
width: 185px; /*Width of left column in pixel*/
margin-left: -900px; /*Set margin to that of -(MainContainerWidth)*/
background: #FFF;
border-right: 1px dotted #97BF97;
}
#rightcol {
float: left;
width: 185px; /*Width of left column in pixel*/
margin-left: -900px; /*Set margin to that of -(MainContainerWidth)*/
background: #FFF;
border-right: 1px dotted #97BF97;
}
#footer {
clear: left;
width: 100%;
background: #fff;
color: #FFF;
text-align: center;
padding: 4px 0;
}



Reply With Quote





Bookmarks