采用jquery easyui loading css效果实现加载时的页面覆盖功能
//采用jquery easyui loading css效果
function ajaxLoading() {
$("<div class=\"datagrid-mask\"><iframe id=\"iframe1\" src=\"about:blank\" frameBorder=\"0\" marginHeight=\"0\" marginWidth=\"0\" style=\"position:absolute; visibility:inherit; top:0px;left:0px;width:100%; height:100%;z-index:-1; filter:alpha(opacity=0.5);\"></iframe></div>").css({ "display": "block", "z-index": "999999", "left": ($(document.body).outerWidth(true) - 400) / 2, "top": ($(window).height() - 350) / 2, "width": "450px", "height": "200px" }).appendTo("body");
$("<div class=\"datagrid-mask-msg\"></div>").html("正在查询数据,请稍候。。。").appendTo("body").css({ "display": "block", "left": ($(document.body).outerWidth(true) - 190) / 2, "top": ($(window).height() - 200) / 2 });
}
function ajaxLoadEnd() {
$(".datagrid-mask").remove();
$(".datagrid-mask-msg").remove();
}