...

View Full Version : 3 column, centered with 100% heights hybrid



steelfishd
12-22-2007, 11:27 PM
HI,

I am putting together a 3 column, centered with 100% hybrid design. And I almost had it perfect. I just need a little help please see this page:
http://www.sscms.edu/Library/librarytest/test2.htm

The library image need to be a fixed height for a flash file. The left column and two columns below image need to be 100% height. I added some code now things are not lining up as they did before..My first issue is with the left box not reaching bottom. Now I need to get the two columns lined up.

You can view the source on the link page but here is the style sheet:




html {height: 100%;}

body
{
background-image: url(images/background.gif);
background-repeat: repeat;
margin-top:0px;
height:100%;
text-align: center;
margin-left: auto;
margin-right: auto;

}

#mainContainer {
margin: 0 auto; /*** Centers the design ***/
text-align: left; /*** Because we centered the text in body we have to move the text back to left aligning ***/
width: 811px;
min-height: 100%;
margin-left: auto;
margin-right: auto;
}
* html #mainContainer {
height: 100%; /*** IE doesn't support min-height, but instead it handles height as min-height so we need to hack the height ***/
}

#float {
border: 0px;
width: 811px;
height: 100%;
position: absolute;

}

#header
{
width: 811px;
height: 82px;
top: 0px;
background-image:url(images/title.gif);
border: solid;
border-top: 1px #000000;
border-right: 1px #000000;
border-left: 1px #000000;
border-bottom: 0px;
}

#headertwo
{
width: 811px;
height: 10px;
background: #8D0F0D;
}

#mainnav
{
height: 25px;
background-color: green;
}

#menu
{
float: left;
margin-left: 0;
width: 215px;
height: 100%;
background-color: #D5D0A9;
text-align: left;
border: solid;
border-top: 0px #000000;
border-right: 1px #000000;
border-left: 0px #000000;
border-bottom: 0px #000000;
}
#menu ul
{
border: solid;
border-top: 0px #000000;
border-right: 0px #000000;
border-left: 0px #000000;
border-bottom: 1px #000000;
font-family: Georgia, "Times New Roman", Times, serif;
font-size: 12px;
line-height: 24px;
text-align: left;
text-decoration: none;
}
#menu li
{
list-style: none;
margin: 0;
border-top: 1px solid black;
font:"Times New Roman", Times, serif;
font-size: 16px;
padding-left: 5px;

}


#contents
{
margin-left: 215px;
text-align: left;
height: 300;
top: 0;
width: 595px;
}
#contentstwo
{
float:left;
width: 301px;
height: 300px;
background-color: #D5D0A9;
border: solid;
border-top: 1px #000000;
border-right: 1px #000000;
border-left: 0px #000000;
border-bottom: 0px #000000;

}
#contentsthree
{
margin-left: 525px;
width: 293px;
height: 300px;
background-color: #D5D0A9;
border: solid;
top: 0;
border-top: 1px #000000;
border-right: 1px #000000;
border-left: 1px #000000;
border-bottom: 0px #000000;
}

#footer {
clear:left;
margin:0 auto;
text-align:center;
width:811px;
height: 20px;
background: #000000;
z-index: 1;
}
p.copywrite
{
font-size: 10px;
margin-bottom: 3px;
margin-top: 3px;
font-weight: normal;
color: #FFFFFF;
text-align: center;
font: Arial, Helvetica, sans-serif;
}

Excavator
12-22-2007, 11:56 PM
Hello steelfishd,
You can't give everything 100% height, stack them on top of each other and have them to stay in one screen height.
Take the aqua colored div out and the footer is still pushed below the bottom of the screen.
It would be better to use an image for your columns I think, like this: http://nopeople.com/CSS/full-height-3column/. You should be able to position your flash file in that...

vexen
12-23-2007, 02:28 PM
Yes, either faux columns as excavator proposed or you could use javascript to get the result



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum