I am trying to achieve this, when the user is scrolling-disable one element. When the user is not scrolling, revert the element to original state.
It is not a problem to make the first requirement, I don't know how to reverse it to previous state. Here is the code for doing something while the user is scrolling:
$(window).scroll(function(){
$('#box').css('display','none');
});
I tried with if-else statements, but I haven't got it to work. Here is the fiddle to see it on hand: