Created
May 15, 2013 23:25
-
-
Save JKring/5588237 to your computer and use it in GitHub Desktop.
fun scrolly time
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var BUFFER = $(window).height() - $("#box").height(); | |
$(window).scroll(function(){ | |
$(window).scrollTop() > BUFFER ? $("#box").hide() : $("#box").show(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment