如果服务器端执行时间很长,在客户端先显示等候画面
2007-07-25 18:48
323 查看
<html>
<head>
<title>梅花雪的页面加载</title>
<script language="javascript">
document.write('<div id=loadDiv style="padding-top:50; padding-left:50">'+'页面正在载入,请稍等<span id="loading"></span></div>');var setInterval1 = setInterval("loading.innerText += '.'",300);
var setInterval2 = setInterval("loading.innerText = ''",15000);
function window.onload()
{
hiddenDiv.style.display=""; //显示页面内容
loadDiv.removeNode(true);
clearInterval(setInterval1);
clearInterval(setInterval2);
}
</script>
</head>
<body>
<div id=hiddenDiv style="display:none">
<!--将网页所有的内容都放在这个div之内即可-->
</div>
</body>
</html>
-------------------------------------------------------------
摘自梅花雪帖子:http://topic.csdn.net/t/20040326/16/2890649.html
<head>
<title>梅花雪的页面加载</title>
<script language="javascript">
document.write('<div id=loadDiv style="padding-top:50; padding-left:50">'+'页面正在载入,请稍等<span id="loading"></span></div>');var setInterval1 = setInterval("loading.innerText += '.'",300);
var setInterval2 = setInterval("loading.innerText = ''",15000);
function window.onload()
{
hiddenDiv.style.display=""; //显示页面内容
loadDiv.removeNode(true);
clearInterval(setInterval1);
clearInterval(setInterval2);
}
</script>
</head>
<body>
<div id=hiddenDiv style="display:none">
<!--将网页所有的内容都放在这个div之内即可-->
</div>
</body>
</html>
-------------------------------------------------------------
摘自梅花雪帖子:http://topic.csdn.net/t/20040326/16/2890649.html
相关文章推荐
- 显示客户端页面执行时间的代码(收藏)
- [Web]显示客户端页面执行时间的代码
- 如何显示history命令的执行时间
- 客户端脚本调用服务器端动态内容,移动到链接显示预览
- .NET服务器端按钮在客户端点击后禁用,服务端执行完事件后再次激活
- 执行sql时显示执行时间
- 服务器端按钮添加客户端事件(确定、取消执行)
- asp.net利用多线程执行长时间的任务,客户端显示出任务的执行进度的示例(二)
- 在客户端获取服务器端的时间
- 关于客户端与数据库服务器端的时间同步问题
- Android中数据文件解析(Json解析【从服务器端获取数据并且解析,显示在客户端上面】)
- .net 客户端如何要显示服务器端的非根目录下的图片,路径该怎么写
- asp.net利用多线程执行长时间的任务,客户端显示出任务的执行进度的示例(一)-asp.net关注
- JSP 如何在客户端同步显示服务器时间
- UNIX网络编程学习(8)--服务器端显示客户端的IP地址和端口号
- mysql显示SQL语句执行所消耗的时间
- mysql显示SQL语句执行时间
- 让服务器控件的事件同时执行客户端脚本和服务器端代码-转载