Silversleaves
E info@silversleaves.com
T +44 121 288 2824
  • Website Design
  •  ·
  • Commercial Photography

  • Database Development
  •  ·
  • Business Intelligence
  • Home
  • Silversleaves
    • Services
    • Portfolio
  • Web
    • CSS
      • Sticky Footer
      • CSS3 Opacity
    • Firefox Addons
      • DGSCheck
  • Database
    • Oracle Certification
      • SQL Fundamentals I - Part 1
        • Introduction
        • Normalisation
        • Relational Theory
        • DESCRIBE
      • SQL Fundamentals I - Part 2
        • SQL Operators & Expressions
        • WHERE
        • ORDER BY
        • Ampersand Substitution
      • SQL Fundamentals I - Part 3
        • Single Row Functions
        • Conversion Functions
        • Group Functions
      • SQL Fundamentals I - Part 4
        • Joining Tables
        • Subqueries
        • Set Operators
        • DML
        • Transactions
      • SQL Fundamentals I - Part 5
        • Manipulating Tables
        • Schema Objects
  • Business Intelligence
    • Coming Soon
  • Photography
    • Food
      • Sweet
      • Savory
    • Drink
      • Liquids
    • Interior
      • Hotel
  • Graphic Design
    • Branding
      • Logos
    • Print
      • Poster
      • Brochure
      • Advert
  • Partners
    • Élite Hotels, Turkey
    • Terzioğlu İnsaat, Turkey
  • Blog
  • CV

CSS Techniques - Sticky Footer

  • Description
  • The Code
  • Notes

Sticky Footer

Interested in the sticky footer on this site? The technique used is pure css taken from http://ryanfait.com/.

After trying various methods of keeping the footer at the bottom of the page, I chose this as it has the best cross browser compatability (IE5+ , Firefox, Safari, Chrome and Opera), and relied solely on css.

A stripped down demo can be seen here.

CSS

HTML

Notes

All the website content must be after the #stick-footer DIV starts, and before the .push DIV begins.

The negative margin for sticky footer must be equal to the height of the .push and #footer divs (this will need to include borders and padding).

© Silversleaves Limited 2013