treehouse : what would you like to learn today?
Web Design Web Development iOS Development

Problem with setting Footer to end of page

  • I have made this jsfidle: http://jsfiddle.net/XWUQn/

    i want the footer at the bottom of the page but so that nothing else changes other than that.

    Would really appreciate any help
    Thanks
  • if i apply the p.main class it is all the time on the top, without class it is at the bottom...
  • Remove float: left; from p.main, and you will see that the footer will move to the bottom. Removing the relative positioning will also help. Floats can some times be a bit of a pain, and relative/absolute positioning should really be thought through before using. I could go on about why these work the way they do, but I recommend reviewing Chris's video tutorials on floats and another on positioning. Chris is a very good teacher!
  • Thanks Mikefmi :)
  • or you could add clear:both to the footer...
    http://jsfiddle.net/XWUQn/17/