zoukankan
html css js c++ java
使用半透明的DIV实现禁用页面功能(转)
实现功能:弹出一个DIV层提示等待信息,这个时候禁用用户操作页面中的其他内容。
弹出DIV:
<
div
id
="divWaiting"
style
="display: none; z-index: 1100; left: 25%; right: 25%; position: absolute;
text-align: center; 50%; height: 50px; border-right: #009900 1px solid;
border-top: #009900 1px solid; border-left: #009900 1px solid; border-bottom: #009900 1px solid;
background-color: #f9fff6; left: expression((this.offsetParent.clientWidth/2)-(this.clientWidth/2)+this.offsetParent.scrollLeft);
top: expression((this.offsetParent.clientHeight/2)-(this.clientHeight/2)+this.offsetParent.scrollTop);"
>
<
br
>
The system is dealing with your request, please waiting
</
div
>
弄一个全屏的DIV来覆盖页面:
<
div
id
="divDisable"
style
="display: none;expression(document.body.offsetWidth);height:expression(document.body.offsetHeight); z-index: 1000; position: absolute;left: 0px; top: 0px;filter:alpha(opacity=50); background-color:White"
></
div
>
点击按钮的操作:
document.getElementById("divWaiting").style.display="";
document.getElementById("divDisable").style.display="";
其他处理:
function ChangeDiv()
{
document.getElementById("divDisable").style.height=document.body.offsetHeight+document.body.scrollTop;
}
window.onscroll=ChangeDiv;
查看全文
相关阅读:
561. Array Partition I
448. Find All Numbers Disappeared in an Array
136. Single Number
485. Max Consecutive Ones
463. Island Perimeter
496. Next Greater Element I
344. Reverse String
【.net项目中。。】.net一般处理程序使用方法
【ExtAspNet学习笔记】ExtAspNet控件库中常见问题
用VS2010创建三层架构开发模式及三层架构的研究
原文地址:https://www.cnblogs.com/skyblue/p/1187691.html
最新文章
centos安装报错:license information (license not accepted)
LVM拓展报错及处理
cobbler安装4个报错汇总及解决方法:ImportError
rz上传文件报错:rpm Read Signature failed: sigh blob(1268): BAD, read returned 0
不同版本docker修改存储位置补充
docker起不来报错:Failed to start Docker Application Container Engine.
最小锁的情况添加 not null 约束
pg中删除的页是否仍被访问
postgresql 数据库无法启动
pg数据库杀掉连接
热门文章
CentOS7防火墙firewalld使用
pg删除账号,权限的回收问题
Cannot enlarge string buffer containing XX bytes by XX more bytes
pg_upgrade升级报错:Only the install user can be defined in the new cluster
WARNING: pgstat wait timeout
PostgreSQL 修改字段类型从int到bigint
476. Number Complement
461. Hamming Distance
412. Fizz Buzz
500. Keyboard Row
Copyright © 2011-2022 走看看