tags:

views:

165

answers:

7

How can I get my footer to be at the bottom of the container, after everything in main?

Here's the site: (It's fine on the homepage, but not on any of the others) http://dl.dropbox.com/u/122695/ds/index.html

+1  A: 

is this solve your problem ?

.footer { clear:both !important;}
Puaka
unfortunately it doesn't
mdogg
this should work, but you have to move the footer outside the #container you slider contains absolute position divs..footer { width: 960px;text-align:center;margin: 3em auto;}
Puaka
when I do that it puts the footer in the middle of the page for whatever reason
mdogg
ok.. try this, put <br clear="all" /> just before footer div.
Puaka
dont forget the css above
Puaka
+1  A: 

Remove height: 200px from .panels h6. IT should work for you.

Elie
didn't work. It has to do with overflow right?
mdogg
Yes, there's an h6 overflowing and clear: both will not solve it.I unchecked the height: 200px from my DOM inspector and it worked exactly they way you want it.
Elie
yea you're right, that problem was in bodytext as well. It was the fixed height. Thanks. How can I get the border to be a set height?
mdogg
A: 

What you are looking for is called a sticky footer. Google for it and you will find a bunch of different options. This is what I use link text

patricksweeney
I don't want the footer at the bottom of the page always, I just want it at the bottom of the content
mdogg
A: 

On your home page your "footer" div is outside your "main" div. On the internal pages (I checked "about") it's inside that "main" div. Fix that and see if the problem goes away?

pjmorse
I fixed it, still doesn't work.
mdogg
A: 

Use clearfix on your main div.

Jeffery To
A: 

You have a few problems in your layout. You must first get rid of fixed heights or increase them as much as possible. Here is the rule that has the problem:

.panels h6 {
  border-left: 1px dotted;
  border-top: 1px solid;
  font-family: verdana;
  font-size: 11px;
  height: 200px;
  /* height 200 px is less than the required height which should be ~244px */
  line-height: 1.3;
  padding: 10px;
}

Next step is optional but recommended to prevent further problems: Inside all elements that contain multiple floated elements, add the following after all floated elements:

<div style="clear: both;"></div>

This will automatically set the height of that element.

Edit ----

Set .panels h6 { height: 200px; overflow-y: scroll; ... }. Then use JavaScript to get and set the height of all three columns equal to the height of tallest column. You can use Prototype functions such as Element.getHeight( ) and Element.setStyle( ) to do this.

Alternately, google "CSS Faux Columns" or "CSS Equal Height Columns".

Salman A
yea that's the problem. I set the height to be 200px so that the left border would be uniform. Is there any way I can set the border to be a certain height?
mdogg
A: 

i'e used sticky footer to solve this problem before

pixeltocode