I want to add a small down arrow on my website when users scroll down and an arrow pointing up when they scroll up.
The only thing I managed to do is
$(document).ready(function(){ $(window).scroll(function () { $("#bottomArrow").show(); setTimeout(function(){ $("#bottomArrow").fadeOut() }, 2000); }); });
which does not recognize up and down, just a "scroll".
How can I do this using jQuery?
Thanks:)
user282294
source share