I\'m using the scrollTo jQuery plugin and would like to know if it is somehow possible to temporarily disable scrolling on the window element through Javascript? The reason
The simplest method is:
$("body").css("overflow", "hidden"); // Remove the scroll bar temporarily
To undo it:
$("body").css("overflow", "auto");
Easy to implement, but the only downside is:
This is due to the scroll bar being removed, and the viewport becoming a bit wider.