jQuery has a function called scrollTop which can be used to find the number of pixels hidden above the current page view.
I\'m not really sure why, but there is no s
You could make a pretty simple plugin for this:
$.fn.scrollBottom = function() {
return $(document).height() - this.scrollTop() - this.height();
};
Then call it on whatever element you wanted, for example:
$(window).scrollBottom(); //how many pixels below current view
$("#elem").scrollBottom(); //how many pixels below element