まだわからない場合は、以下のこの簡単な例をご覧ください。
コードコピーは次のとおりです。
<html>
<head>
<title>窓がポップアップした後、後続のレイヤーは動作しません</title>
<スクリプト>
function show()//隠されたレイヤーとポップアップ層を表示します
{
var disobj = document.getElementById( "Hidebg");
hidebg.style.display = "block"; //隠されたレイヤーを表示します
hidebg.style.height = document.body.clientheight+"px"; //隠れ層の高さを現在のページの高さに設定します
document.getElementById( "Hidebox")。style.display = "block"; //ポップアップレイヤーを表示します
}
function hide()//隠されたレイヤーとポップアップレイヤーを削除します
{
document.getElementById( "Hidebg")。style.display = "none";
document.getElementById( "Hidebox")。style.display = "none";
}
</script>
<style>
ボディ{マージン:0px;パディング:0px;テキストアリグイン:センター;}
#hidebg {position:absolute; left:0px; top:0px;
バックグラウンドカラー:#000;
幅:100%; /*幅は100%に設定されているため、隠された背景層が元のページをカバーできます*/
フィルター:アルファ(不透明度= 60); /*透明度を60%に設定*/
不透明度:0.6; /*非IEブラウザで透明性を60%に設定*/
表示:なし; / * //www.vevb.com */
z-index:2;}
#hidebox {position:absolute; width:400px; height:300px; top:200px; left:30%; background-color:#ffff; display:none; cursor:pointer; z-index:3;}
#content {text-align:center; cursor:pointer; z-index:1;}
</style>
</head>
<body>
<div id = "hidebg"> </div>
<div id = "hidebox" onclick = "hide();">クリックして閉じる</div>
<div id = "content" onclick = "show();">クリックしてtry </div>
</body>
</html>