I'm trying to get a footer to stick to the bottom with jQuery but only if the document is shorter than the window.
I realize this is possible with some convoluted css, but I thought I'd give it a try with jQuery.
The code below works on Webkit and Firefox but not IE.
How can this be modified to work cross platform?
http://nuttyste.nextmp.net
Thank you ECode:<script type='text/javascript'> $j(document).ready(function(){ d=$j(document).height(); h=$j('html').height(); if(d>h){ $j('#footer').css({'position':'absolute', 'bottom':0,'width':'100%'}); } }); </script>



Reply With Quote


Bookmarks