2 replies [Last post]
ferellie
Offline
newbie
Last seen: 15 years 49 weeks ago
Joined: 2006-10-31
Posts: 2
Points: 0

Hello,
I am using a 2 col layout with a footer that's set to clear both floating divs.
Problem is it completely ignores my sidebar in IE6, Mozilla is fine.
The problem arises when the sidebar div is longer than the content div the footer comes up and into div sidebar in IE6.

Any help would be fantastic as I just can't seem to sort it out.

* {
margin: 0px;
padding: 0px;
}

body {
font-family: "Trebuchet MS";
font-size: 10px;
}

#header {
background-color: #FFFFCC;
height: 5em;
margin-bottom: 5px;
}

#content {
float: right;
font-size: 1.2em;
margin-bottom: 0.5em;
background-color: #FFCC99;
text-align: left;
padding-right: 3em;
padding-left: 16em;

#sidebar {
float: left;
width: 15.5em;
font-size: 1.2em;
margin-bottom: .5em;
margin-right: -16em;
background-color: #CCCCCC;
margin-left: 0px;

#footer {
background-color: #003399;
clear: both;
margin-top: 1em;

Much appreciated,
Ferellie

cmanciero
cmanciero's picture
Offline
Regular
East Haven, CT USA
Last seen: 9 years 10 weeks ago
East Haven, CT USA
Timezone: GMT-4
Joined: 2006-10-11
Posts: 13
Points: 0

Did you try a wrapper div?

Have you tried surrounding the content and sidebar div's with a wrapper div and setting a width to the wrapper div.

<div id="header" />
<div id="wrapper" >
<div id="content" />
<div id="sidebar" />
</div>
<div id="footer"/>

ferellie
Offline
newbie
Last seen: 15 years 49 weeks ago
Joined: 2006-10-31
Posts: 2
Points: 0

Thank you

Yep,

That was a bit too eay but it worked fine.
I tried the wrapper before setting overflow to auto too but not with a width!

Thanks