Jump to content

Container not as tall as its content


The Little Guy

Recommended Posts

I have a div that is a container, and it is centered on the page, then I have have div's inside of it which are floated.

 

When I display it it displays weird...

 

I want that div to be below the white box. The white box is inside the container, and the container is only as high as the y position of the red box.

 

how can I make the container be as tall as its content?

 

Container:

#container{
margin:auto;
margin-top:40px;
min-height:200px;
width:800px;
position:relative;
}

 

Content:

.content{
float:left;
padding:10px;
width:100%;
clear:both;
background-color:#FFF;
-moz-border-radius:20px;
-webkit-border-radius:20px;
border-radius:20px;
-moz-box-shadow: 0 0 10px #000;
-webkit-box-shadow: 0 0 10px #000;
box-shadow: 0 0 10px #000;
}

 

[attachment deleted by admin]

Link to comment
https://forums.phpfreaks.com/topic/196202-container-not-as-tall-as-its-content/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.