layer请求设置遮罩

layer请求设置遮罩

//设置遮罩等待文件上传完成
    var index = layer.load(1, {
        shade: [0.1,'#fff'] //0.1透明度的白色背景
    });
    
    $.ajax({
        type : "POST",
        url : Feng.ctxPath + url,
        data : formData,
        async : false,
        cache : false,
        contentType : false,
        processData : false,
        success : function(data) {if (data.code == '200') {
                Feng.info("上传成功");
            } else {

                Feng.info("报错了: " + data.msg);
            }
        },
        error : function(XMLHttpRequest, textStatus, errorThrown, data) {
            Feng.error("上传失败,请重试");
        }
    });
  //删除图片遮罩
  layer.close(index);
 

 

posted @ 2018-08-23 10:37  泡沫幻影  阅读(988)  评论(0编辑  收藏  举报