弹出遮罩层后禁止滚动效果【实现代码】
内容摘要
方法一:
$('.shade').bind( "touchmove", function (e) {
e.preventDefault();
});
方法二:
$("body,.main").height($(window).height()).css({
"overflow-y": "h
$('.shade').bind( "touchmove", function (e) {
e.preventDefault();
});
方法二:
$("body,.main").height($(window).height()).css({
"overflow-y": "h
文章正文
方法一:
$('.shade').bind( "touchmove", function (e) { e.preventDefault(); });
方法二:
$("body,.main").height($(window).height()).css({ "overflow-y": "hidden" });
以上这篇弹出遮罩层后禁止滚动效果【实现代码】就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持phpstudy。
代码注释