87,910
社区成员
发帖
与我相关
我的任务
分享
<!doctype html>
<html>
<head>
<meta charset="gb2312">
<title>无标题文档</title>
<script type="text/javascript" src="jquery1.7.js"></script>
<script type="text/javascript">
$(document).ready(function(e) {
$("#button").click(function(e) {
$("[style*='z-index:1']").hide()
});
});
</script>
</head>
<body>
<div style="z-index:1" id="div1">1</div>
<div style="z-index:2" id="div2">2</div>
<div style="font-size:24px;z-index:1" id="t3">1</div>
<form name="form1" method="post" action="">
<input type="button" name="button" id="button" value="点击按钮隐藏z-index:1的层">
</form>
</body>
</html>