IE继续给我留下下至最后一行的错误,称“目标需要”。 我不敢确定这个问题在哪里。 任何建议?
function showdiv()
{
document.getElementById("dialogue").style.display = "";
document.getElementById("screen").style.display = "";
document.getElementById("screen").style.width = getBrowserWidth();
}
function hidediv(opt){
if(opt=="agree"){
document.Annexation.checkbox.checked = true;
document.getElementById("dialogue").style.display = "none";
document.getElementById("dialogue").style.display = "none";
document.getElementById("screen").style.display = "none";
}else{
document.getElementById("dialogue").style.display = "none";
document.getElementById("screen").style.display = "none";
}}
window.onscroll = scrollEvent;
function scrollEvent() {
var y;
if (document.documentElement && !document.documentElement.scrollTop)
// IE6 +4.01 but no scrolling going on
y=document.documentElement.scrollTop;
else if (document.documentElement && document.documentElement.scrollTop){
// IE6 +4.01 and user has scrolled
y=document.documentElement.scrollTop;
}
else if (document.body && document.body.scrollTop){
// IE5 or DTD 3.2
y=document.body.scrollTop;
}
document.getElementById("screen").style.top = y+"px";
}