Jump to content

3 Col : Div under div


tarleton

Recommended Posts

Hi so I'm super new to CSS. Trying to make a 3 col layout (yes I know there are some on the net already but trying to learn). Got a few problems:

 

1. Right Column isn't staying near header.

2. Mid column isn't going to full length like left column.

3. There is a white border around entire page.

 

Thanks for any help guys.

 

Here is what i've got so far: www.spacioushost.com/test

 

style.css

#header {
background: #000;
height:55px;
width:100%;
}

#leftcol {
position: absolute;
width: 15%;
height: 100%;
background:url(images/left_col.jpg) repeat;

}


#rightcol {
width: 15%;
height: 100%;
background:url(images/right_col.jpg) repeat;
float: right;


}

#midcol {
background: #232323;
width: 70%;
height: 100%;
margin-left: 15%;
}

Link to comment
https://forums.phpfreaks.com/topic/180815-3-col-div-under-div/
Share on other sites

try this out

 

#header {
   background: #000;
   height:55px;
   width:100%;
}

#content {width:100%;padding:0px}

#leftcol {
   width: 15%;
   height: 100%;
   background:url(images/left_col.jpg) repeat;
   float:left
}


#rightcol {
   width: 15%;
   height: 100%;
   background:url(images/right_col.jpg) repeat;
   float:left
}
   
#midcol {
   width: 70%;
   height: 100%;
   float:left
}

Link to comment
https://forums.phpfreaks.com/topic/180815-3-col-div-under-div/#findComment-953916
Share on other sites

body {
background-color: #FFF;
}

#header {
background: #000;
height:55px;
width:100%;
}

#leftcol {
display: inline; float: left;
width: 15%;
height: 100%;
background:url(images/left_col.jpg) repeat;

}


#rightcol { display: inline; float: left;
width: 15%;
height: 100%;
background:url(images/right_col.jpg) repeat;



}

#midcol {
        display: inline; float: left;
background: #232323;
width: 70%;
height: 100%;

}

just edited what you had in firebug. works great!

 

[attachment deleted by admin]

Link to comment
https://forums.phpfreaks.com/topic/180815-3-col-div-under-div/#findComment-954192
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.