function aa()
{
var bgObj = document.createElement("div");
bgObj.style.cssText = "position:absolute;left:0px;top:0px;FILTER:alpha(opacity=60);background:#999999;width:"+document.documentElement.clientWidth+"px;height:"+Math.max(document.body.clientHeight,document.documentElement.clientHeight)+"px;z-index:1;"
document.body.appendChild(bgObj);  var denglu = document.createElement("div");
denglu.style.cssText = "position:absolute;left:"+(document.documentElement.clientWidth-590)/2+"px;top:"+(Math.max(document.body.clientHeight,document.documentElement.clientHeight)-440)/2+"px;width:590px;height:394px;background:#ffffff;z-index:2;";
document.body.appendChild(denglu);
document.body.style.cssText = "margin:0; text-align:center; font-size:14px; font-family:Tahoma;";
denglu.innerHTML = "<iframe src='2Enter.html' height='394' width='590' frameborder='0' scrolling='auto' marginwidth='0' marginheight='0'></iframe>";

var closes = document.createElement("div");
closes.style.cssText = "position:absolute;left:"+((document.documentElement.clientWidth-590)/2 + 590 - 58)+"px;top:"+(Math.max(document.body.clientHeight,document.documentElement.clientHeight)-440)/2+"px;width:58px;height:20px;z-index:3;";
closes.innerHTML = "<input name='closeAll' type='image' src='images/close.gif' onclick='javascript:hiddendiv()' />";
document.body.appendChild(closes);
}
function hiddendiv()
{
bgObj.style.display = "none";
denglu.style.display = "none";
closes.style.display = "none";
}
function xsdiv()
{
bgObj.style.display = "block";
denglu.style.display = "block";
closes.style.display = "bolck";
}
为什么点击按钮后,方法执行了。但是没把层隐藏了