Hi,
I’ve looked around and read all the sticky footer guides, both CSS and Jquery. The problem is, every technique I use makes the footer sit below the window height. I have to scroll to see it.
There is probably something in my existing code interfering with it. Can anyone help?
Jquery technique:
if($(document.body).height() < $(window).height()){
$('#footer').css({
position: 'absolute',
top: ( $(window).scrollTop() + $(window).height()
- $("#footer").height() ) + "px",
width: "100%"
});
} else {
$('#footer').css({
position: 'static'
});
}
CSS technique :https://css-tricks.com/snippets/css/sticky-footer/
Footer:
footer {
background-color: #F1F1F1;
border-top: 1px solid #CCC;
height: 80px;
text-align: center;
width: 100%;
}