javascript - white space at the bottom of page -



javascript - white space at the bottom of page -

the problem have site keeps giving big white space on bottom of page, thought why happening?

i have css on content:

#content{ width: 990px; margin: 0 auto; min-height: 100%; height: auto !important; height: 100%; margin: 0 auto -40px; position: relative; } .full-background { z-index: -999; min-height: 100%; min-width: 1024px; width: 100%; height: 100%; position: fixed; top: 0; left: 0; }

and i´m using script fit background image window:

function fittobox(){ $('.fittobox').each(function(){ $(this).fittobox(); }) } $(window).bind({ 'load' : fittobox, 'resize' : fittobox })

update function

// fittobox jquery.fn.fittobox = function(){ var div = this.parent(); var img = this; var imar = img.attr("height") / img.attr("width"); var bgar = div.height() / div.width(); if(imar >= bgar){ img.attr("width" , div.width()); img.attr("height" , div.width() * imar); }else{ img.attr("height" , div.height()); img.attr("width" , div.height() / imar); } div.css({ "position" : "absolute", "overflow" : "hidden" }); img.css({ "position" : "absolute", "left" : (div.width() - img.attr("width"))/2, "top" : (div.height() - img.attr("height"))/2 }); img.fadein(); };

thanks!

if remove body height:100% , create #footer position:absolute there no gap.

javascript jquery html css

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -