Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

CSS float causes containing div to not extend full height

Posted on 2012-03-20
1
Medium Priority
?
655 Views
Last Modified: 2012-03-20
We have a page with the following setup:

<div id="wrapper">
<div id="col1">
content
</div>
<div id="col2">
content
</div>
<div>

We use float: left on col1 & col2 for positioning.  There is a background color applied to "wrapper", however we are finding that the height of "wrapper" does not extend the full height of the content in col1 & col2.  We've spent all day trying variations and breaking the markup & styles down, having trouble determining why the container div does not extend.

Here is an example page: http://hovercrafts.d3t.biz/content.html

You can see the main content area has a content and a sidebar.  The light-colored box near the content is supposed to be the full height of the content area (it is a container div for the content area).

Any thoughts on what we are doing wrong?  I'm sure it's something obvious, but we are missing it.  Thanks.
0
Comment
Question by:dageyra
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 1

Accepted Solution

by:
dageyra earned 0 total points
ID: 37745334
Just worked it out, we were missing a <div class="clear"></div> after the columns!
0

Featured Post

Certified OpenStack Administrator Course

We just refreshed our COA course based on the Newton exam.  With 14 labs, this course goes over the different OpenStack services that are part of the certification: Dashboard, Identity Service, Image Service, Networking, Compute, Object Storage, Block Storage, and Orchestration.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Originally, this post was published on Monitis Blog, you can check it here . It goes without saying that technology has transformed society and the very nature of how we live, work, and communicate in ways that would’ve been incomprehensible 5 ye…
When the s#!t hits the fan, you don’t have time to look up who’s on call, draft emails, call collaborators, or send text messages. An instant chat window is definitely the way to go, especially one like HipChat. HipChat is a true business app. An…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

664 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question