easyui页面加载错乱解决方法提示正在加载请稍等
https://www.flypeng.com win10系统 发布时间:2015-08-31 00:00 来源:未知

/*

文件说明:页面加载时Loading JS

文件描述:解决IE或FF下,初始化加载时,页面布局乱掉的问题

*/
将以下代码粘贴到js文件中,页面直接导入该js文件即可

var width = $(window).width();

var height = $(window).height();

 var html = "<div id='loading' class='panel-body' style='z-index:1000;position:absolute;left:0;width:100%;height:" + height + "px;top:0;'>";

html += "<div  class='panel-header panel-loading' style='position:absolute;cursor1:wait;left:" + ((width / 2) - 100) + "px;top:200px;width:150px;height:16px;padding:5px 5px 10px 30px;font-size:12px;";

html += "border:3px solid #ccc;'>";

html += "正在加载,请等待...";

html += "</div>";

html += "</div>";

document.write(html);

function closes() {  

    $("#loading").fadeOut("fast", function () {  

        $(this).remove();  

    });  

}  

var pc;  

$.parser.onComplete = function () {  

    if (pc) clearTimeout(pc);  

    pc = setTimeout(closes, 1000);  

}

 

 

 


如果你有好的win10资讯或者win10教程,以及win10相关的问题想要获得win10系统下载的关注与报道。
欢迎加入发送邮件到#qq.com(#替换为@)。期待你的好消息!