Solved

CSS float causes containing div to not extend full height

Posted on 2012-03-20
1
651 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
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

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
window close link 7 32
javascript form - error when hitting enter 3 26
Secure log in 'box' 4 8
title attribute 5 23
FAQ pages provide a simple way for you to supply and for customers to find answers to the most common questions about your company. Here are six reasons why your company website should have a FAQ page
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

713 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