您的位置:首页 > 其它

A mask of the web~

2008-10-13 14:41 274 查看
this is a simple realization of mask. the code as below:
<!doctype html public "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title> New Document </title>
<meta name="Generator" content="EditPlus">
<meta name="Author" content="">
<meta name="Keywords" content="">
<meta name="Description" content="">
<style type="text/css">
#mask {
position: absolute;
visibility: hidden;
background: #000;
z-index: 99999;
left: 0px;
top: 0px;
filter: alpha(opacity=80);
text-align: center;
}
</style>
<script type="text/javascript">
var o;
function showMask() {
o = document.getElementById("mask");
o.style.visibility = "visible";
o.style.height = window.screen.availHeight;
o.style.width = window.screen.availWidth;
}

function closeMask() {
o = document.getElementById("mask");
o.style.visibility = "hidden";
}
</script>
</head>

<body>
<div id="mask"><input type="button" value="close" onclick="closeMask()" /></div>
<input type="button" value="showMask" onclick="showMask()" />
</body>
</html>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐