• Resolved Admiral

    (@aadmiral)


    Hello,

    How can I attach a Footer to the bottom of the screen? Forever and regardless of the content on the page.
    Currently, the footer is located right after page if the content on the page a bit – https://i.imgur.com/8cQcOtC.png

    And how can I limit the width of the footer – as page size (like in boxed layout, but not using it)?

    Thanks in advance

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi,

    Easiest way is to set a higher max height for the page, so that the footer is never hanging like that:

    .main-inner { max-height: 700px; }

    If you want to go the javascript way instead, here is a sticky footer script that works with different footer heights:
    https://www.drupalcoder.com/blog/cross-browser-sticky-footer-with-fluid-height-using-jquery.html

    To limit the width of the footer, do:

    #footer-bottom { margin: 0 auto; max-width: 1280px; }

    Thread Starter Admiral

    (@aadmiral)

    Okay, thanks.

    But still stuck with footer limitation.

    Page limited to 1024px.

    .container-inner { max-width: 1024px; }

    Set your code with my value:

    #footer-bottom { margin: 0 auto; max-width: 1024px; }

    Result – footer are not the same with page https://i.imgur.com/PaA4lnB.png
    And how to remove white background effect on footer?

    .main-inner { max-height: 700px; }

    This code has no effect, or am I doing something wrong.
    Using 1300px as well.
    I will try method with javascript later.

    Sorry, I meant min-height, not max-height for the main-inner one.

    For the footer, try this instead:

    #footer { margin: 0 auto; max-width: 1024px; }

    Thread Starter Admiral

    (@aadmiral)

    It works! Many thanks.

    With sticky footer – I will try to do using javascript.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Footer’ is closed to new replies.