javascript scroll position to element code example
Example: scroll position
$(window).scroll(function() {
var $height = $(window).scrollTop();
if($height > 50) {
//do something
} else {
//do something
}
});
$(window).scroll(function() {
var $height = $(window).scrollTop();
if($height > 50) {
//do something
} else {
//do something
}
});