No replies
bsewell
bsewell's picture
Offline
newbie
London
Last seen: 8 years 40 weeks ago
London
Timezone: GMT+1
Joined: 2010-12-15
Posts: 2
Points: 4

Hi,
I want to get my 2 columns the same height on a webpage. I have a container, and within it a "content" div that is centered and a "sidebar". Right now, I have it so that the sidebar is on the right of the container div. My catch is that I want the sidebar to expand to the same height as the content div.

My CSS code:

.container
{
	width:100%;
	margin-top:10px;
}
 
.sidebar
{
	width:200px;
	background-color:#999999;
	margin-right:5px;
	padding:10px;
	float:right;
	overflow:hidden;
}
 
.content
{
	float:right;
	width:800px;
	background-color:#999999;
	margin-left:auto;
	margin-right:auto;
	padding: 10px;
	margin-bottom:5px;
	text-indent: 10px;
}

Would appreciate it if somebody told me how to get the sidebar to expand (both div's are used in multiple pages).

Cheers,