fix sticker footer
This commit is contained in:
parent
348fd81b75
commit
8d847a9ac4
|
@ -25,7 +25,7 @@ var Init = {
|
||||||
resizeImage: function(){
|
resizeImage: function(){
|
||||||
|
|
||||||
var header = document.getElementById('header'),
|
var header = document.getElementById('header'),
|
||||||
footer = document.getElementById('footer-wrap'),
|
footer = document.getElementById('footer'),
|
||||||
main = document.getElementById('main-content'),
|
main = document.getElementById('main-content'),
|
||||||
vp = window.innerHeight,
|
vp = window.innerHeight,
|
||||||
bodyHeight = document.body.clientHeight,
|
bodyHeight = document.body.clientHeight,
|
||||||
|
@ -33,7 +33,7 @@ var Init = {
|
||||||
fHeight = footer.clientHeight,
|
fHeight = footer.clientHeight,
|
||||||
withMinHeight = hHeight + fHeight + 830;
|
withMinHeight = hHeight + fHeight + 830;
|
||||||
|
|
||||||
if(withMinHeight > bodyHeight ){
|
if(withMinHeight < vp && bodyHeight < vp){
|
||||||
var newHeight = (vp - (hHeight+fHeight)) + 'px';
|
var newHeight = (vp - (hHeight+fHeight)) + 'px';
|
||||||
main.style.height = newHeight;
|
main.style.height = newHeight;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue