用jQuery实现点击页面其他位置,关闭弹出框-成都快上网建站

用jQuery实现点击页面其他位置,关闭弹出框

$(document).click(function (e) {
    var drag = $("#drag"),
        dragel = $("#drag")[0],
        target = e.target;
    if (dragel !== target && !$.contains(dragel, target)) {
        drag.hide();
    }
});

网页题目:用jQuery实现点击页面其他位置,关闭弹出框
文章来源:http://kswjz.com/article/geioig.html
扫二维码与项目经理沟通

我们在微信上24小时期待你的声音

解答本文疑问/技术咨询/运营咨询/技术建议/互联网交流