Forums

Sticky footer (2 posts)

  1. davidzupec
    Member
    Posted 7 months ago #

    Hello, I was having a issue with my footer not sticking to the bottom of my page so I edited my css and now it's fine but for some reason I'm getting an enormous amount of space now between the footer and page content (on all pages) my site is http://www.barefootwebsit.es also here is the code that made the footer rest on the bottom. Did I do something wrong in the css?

    html, body, #page-wrap { height: 100%; }
    
    body > #page-wrap { height: auto; min-height: 100%; }
    
    #content { padding-bottom: 317px; }  /* must be same height as the footer */
    
    #footer { position: relative; margin-top: -317px; /* negative value of footer height */ height: 317px; clear:both; }
  2. peredur
    Member
    Posted 7 months ago #

    This is what's doing it (on line 1 of http://barefootwebsit.es/wp-content/themes/barefoot/css/home.css):

    #content {
      margin-bottom: 75px;
      margin-left: 0;
      margin-right: 0;
      margin-top: 50px;
    }

    and (on line 150 of http://barefootwebsit.es/wp-content/themes/barefoot/style.css):

    #content {
      padding-bottom: 317px;
    }

    So at the bottom of your content you have 317px of padding and 75px of margin. Thus, 392px of space between the bottom of your content and the start of your footer.

    Cheers

    PAE

Reply

You must log in to post.

About this Topic

Tags