/    Sign up×
Community /Pin to ProfileBookmark

#container height will not extend with #content

Okay so there’s this code I wrote and I am using server side includes and I don’t know if that could have something to do with this but anyhow. My container div height will not extend with the content div. I have tried overflow:hidden; clear:both; min-height:100%; height:100%; height:auto; I DON’T KNOW WHAT IS WRONG…. There are divs nested in the #container div, there are two sidebars which I am using ssi’s for and there is the content div. and the container won’t contain the stupid content. Nothing is floated.

body {background-image:url(background.png);
font-family:Tahoma, Geneva, sans-serif;
font-size:12px;
color:#333;
margin:auto;
}

#container {background:#f5efdb;
width:910px;
min-height:1600px;
height:auto;
margin:auto;
margin-top:50px;
text-align:center;
box-shadow:-5px 5px 20px #333;
padding:5px;
overflow:auto;
}

#content {text-align:left;
color:#333;
padding-left:20px;
padding-right:20px;
width:580px;
height:auto;
overflow:auto;
}

#leftside {width:150px;
padding-left:5px;
text-align:left;
}

#rightside {width:150px;
padding-right:5px;
text-align:right;
}

a {color:#685144;
text-decoration:none;
}

td {padding:0px;
text-align:left;
}

#description {text-align:left;
padding:5px;
}

#tdleft {padding:0px;
text-align:right;
}

#tdright {padding:0px;
text-align:left;
}

#tdcenter {padding:0px;
text-align:center;
}

table {padding:5px;
text-align:left;
}

#tdpad {padding:10px;
}

to post a comment
CSS

5 Comments(s)

Copy linkTweet thisAlerts:
@Jeff_MottSep 25.2011 — You'll need to attach or link to the actual page for us to troubleshoot.
Copy linkTweet thisAlerts:
@Jeff_MottSep 25.2011 — It's because your leftside, content, and rightside are positioned absolutely. That takes those boxes out of the normal flow. You'll have to get rid of the absolute positioning and transition to floats.
Copy linkTweet thisAlerts:
@stephaniebeardauthorSep 25.2011 — it still didn't work...


@charset "utf-8";

/* CSS Document */

body {background-image:url(background.png);

font-family:Tahoma, Geneva, sans-serif;

font-size:12px;

color:#333;

margin:auto;

height:auto;

}

#container {background:#f5efdb;

width:910px;

height:auto;

min-height:1600px;

margin:auto;

margin-top:50px;

margin-bottom:50px;

text-align:center;

box-shadow:-5px 5px 20px #333;

padding:5px;

}

#content {text-align:left;

color:#333;

padding-left:20px;

padding-right:20px;

width:550px;

height:auto;

min-height:600px;

float:left;

}

#leftside {width:150px;

padding-left:5px;

text-align:left;

float:left;

}

#rightside {width:150px;

padding-right:5px;

text-align:right;

float:right;

}

a {color:#685144;

text-decoration:none;

}

td {padding:0px;

text-align:left;

}

#description {text-align:left;

padding:5px;

}

#tdleft {padding:0px;

text-align:right;

}

#tdright {padding:0px;

text-align:left;

}

#tdcenter {padding:0px;

text-align:center;

}

table {padding:5px;

text-align:left;

}

#tdpad {padding:10px;

}
Copy linkTweet thisAlerts:
@stephaniebeardauthorSep 25.2011 — In the container, I added overflow:auto; and it works now.

THANK YOU SO SO SO MUCH FOR YOUR HELP!!!!!
×

Success!

Help @stephaniebeard spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...