R
@markus said in How to prevent a page from scrolling?:
$(".page__content").css(“overflow”,“none”);
Thanks! That alone won’t work but led me to a solution:
var height;
function lockScroll()
{
height=$(".page__content").css("height");
$(".page__content").css("height","100%");
$(".page__content").css("overflow","none");
}
function unlockScroll()
{
$(".page__content").css("height",height);
$(".page__content").css("overflow","auto");
}
Problem solved!