Prefix jQuery object variable names with $

master
Keith Irwin 2017-12-21 13:09:06 -05:00
parent caa82bb8b3
commit 1de7ac4ef1
No known key found for this signature in database
GPG Key ID: 378933C743E2BBC0
1 changed files with 4 additions and 4 deletions

View File

@ -3,10 +3,10 @@
// Push footer to bottom on pages with little content // Push footer to bottom on pages with little content
function setFooter () { function setFooter () {
var windowHeight = $(window).height() var $windowHeight = $(window).height()
var footerBottom = $('footer').offset().top + $('footer').height() var $footerBottom = $('footer').offset().top + $('footer').height()
if (windowHeight > footerBottom) { if ($windowHeight > $footerBottom) {
$('footer').css('margin-top', windowHeight - footerBottom) $('footer').css('margin-top', $windowHeight - $footerBottom)
} }
} }