var ie4=document.all&&navigator.userAgent.indexOf("Opera")==-1; var ns6=document.getElementById&&!document.all; var ns4=document.layers; var hider; var pageHeight,pageWidth; var iH,iW; function getDimensions() { if (self.innerHeight) // all except Explorer { iW = self.innerWidth; iH = self.innerHeight; } else if (document.documentElement && document.documentElement.clientHeight) // Explorer 6 Strict Mode { iW = document.documentElement.clientWidth; iH = document.documentElement.clientHeight; } else if (document.body) // other Explorers { iW = document.body.clientWidth; iH = document.body.clientHeight; } var test1 = document.body.scrollHeight; var test2 = document.body.offsetHeight; if (test1 > test2) // all but Explorer Mac { pageHeight = document.body.scrollWidth; pageWidth = document.body.scrollHeight; } else // Explorer Mac; //would also work in Explorer 6 Strict, Mozilla and Safari { pageWidth = document.body.offsetWidth; pageHeight = document.body.offsetHeight; } } function switchColor(theField, color) { if ( typeof(theField.style) == 'undefined' ) { return false; } else { theField.style.backgroundColor=color; } } function imageBox(sender) { var URLStr; URLStr = 'showimage.php?img='+sender.src; win = window.open(URLStr, 'imageBox', 'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbar=no,resizable=yes,copyhistory=yes,width=1,height=1,left=10px,top=10,screenX=10,screenY=10'); win.focus(); } function imageBoxUrl(url) { var URLStr; URLStr = 'showimage.php?img='+url; win = window.open(URLStr, 'imageBox', 'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbar=no,resizable=yes,copyhistory=yes,width=1,height=1,left=10px,top=10,screenX=10,screenY=10'); win.focus(); } function ScaleNPos(image) { var w; var h; var sh,sw; sh = screen.height; sw = screen.width; w = document.images[image].width h = document.images[image].height; self.resizeTo(w+40,h+90); pX = (sw-w)/2; pY = (sh-h)/2; self.moveTo(pX,pY); var iH,iW; if (self.innerHeight) // all except Explorer { iW = self.innerWidth; iH = self.innerHeight; } else if (document.documentElement && document.documentElement.clientHeight) // Explorer 6 Strict Mode { iW = document.documentElement.clientWidth; iH = document.documentElement.clientHeight; } else if (document.body) // other Explorers { iW = document.body.clientWidth; iH = document.body.clientHeight; } var foot=ie4? document.all.foot : ns6? document.getElementById("foot") : ns4? document.foot : "" posX = (iW-w)/2; posY = (iH-h)/2; posX2 = (iW-150)/2; posY2 = posY+h; if (document.getElementById) { document.images[image].style.left = posX + "px"; document.images[image].top = posY + "px"; foot.style.left = posX2 +"px"; foot.style.top = posY2 +"px"; } else if (document.all) { document.images[image].left = posX; document.images[image].top = posY; foot.style.left = posX2; foot.style.top = posY2; } } function helpbox(e,text) { //var hb=ie4? document.all.helpbox : ns6? document.getElementById("helpbox") : ns4? document.helpbox : ""; var hb = document.getElementById('helpbox'); if(!e) { e = window.event; } var y; if (document.body.scrollTop) { y = document.body.scrollTop; } else { y = window.pageYOffset; } var posX = e.clientX; if(!y) { var posY = e.clientY; } else { var posY = e.clientY+y; } if(ie4) { posY = posY+10; posX = posX+10; } hb.innerHTML = text; /* if (document.getElementById) { hb.style['left']= posX + 'px'; hb.style['top'] = posY + 'px'; } else if (document.all) { hb.style['left'] = posX; hb.style['top'] = posY; } */ hb.style['left']= posX + 'px'; hb.style['top'] = posY + 'px'; hb.style['visibility']='visible'; } function hidehelp() { var hb=ie4? document.all.helpbox : ns6? document.getElementById("helpbox") : ns4? document.helpbox : ""; hb.style.visibility="hidden"; } function showmenu(menulist, sender) { var sub=ie4? document.all.submenu : ns6? document.getElementById("submenu") : ns4? document.submenu : "" posX = sender.style.left.substr(0,sender.style.left.indexOf("p")); posY = sender.style.top.substr(0,sender.style.top.indexOf("p"))+sender.style.height; var m = ie4? 18 : 19; sub.innerHTML = linkset[menulist]; if (document.getElementById) { sub.style.left = posX + "px"; sub.style.top = posY+m + "px"; } else if (document.all) { sub.style.left = posX; sub.style.top = posY+m; } sub.style.visibility="visible"; } function hidemenu() { var sub=ie4? document.all.submenu : ns6? document.getElementById("submenu") : ns4? document.submenu : "" sub.style.visibility="hidden"; } function delayhidemenu() { hider = window.setTimeout("hidemenu()",500); } function clearhide() { window.clearTimeout(hider); } hider = window.setTimeout("hidemenu()",2000);