I\'m using the Jquery dialog to open a popup box window on top of a page. When I open the dialog box, I want the general page scrolling to be disabled. To do so, I am doing
you can calculate the difference between the body width, before and after the overflow hidden, and apply it as padding-right to the body
var bodyStartW = $("body").width();
$("body").css("overflow-y" , "hidden");
var bodyEndW = $("body").width();
var bodyMarginL = bodyEndW - bodyStartW;
$("body").css("padding-right" , bodyMarginL);
In Safari you had the same trick for the "html" tag, and margin-right instead of padding-right