1、移动端点击事件无效 解决办法:给点击事件无效的div身上加属性cursor: pointer即可。
2、移动端有个弹窗,弹窗里面有一些可以滚动的内容。希望弹窗弹起来的时候,除弹窗外其他地方不能滚动。思路: 弹窗出现时:
$(window).on(
'touchmove',
function(e){
e.preventDefault();
});
$(
'.scroll-ele').on(
'touchmove',
function(e){
e.stopPropagation();
})
弹窗消失时:
$(window).off(
'touchmove');