var w3c=(document.getElementById)?true:false;var ns4=(document.layers)?true:false;var ie5=(w3c&&document.all)?true:false;var ns6=(w3c&&!document.all)?true:false;var d=document;currIDb=null;xoff=0;yoff=0;currRS=null;rsxoff=0;rsyoff=0;oldac=null;newac=null;zdx=1;mx=0;my=0;var currFb=null;var currFs=null;var currFID=0;var currFcnt=0;var cidlist=new Array();function fadeboxin(a){if((currFb==null)&&w3c){clearInterval(currFID);currFb=d.getElementById(a+"_b");currFs=d.getElementById(a+"_s");if(currFb.style.display=="none"){currFcnt=0;if(ie5){currFb.style.filter=currFs.style.filter="alpha(opacity=0)"}else{currFb.style.MozOpacity=currFs.style.MozOpacity=0}hideAllScrollbars();currFb.style.display=currFs.style.display="block";changez(currFb);currFID=setInterval("sub_fadein()",20)}else{currFb=null}}}function fadeboxout(a){if((currFb==null)&&w3c){clearInterval(currFID);currFb=d.getElementById(a+"_b");currFs=d.getElementById(a+"_s");if(currFb.style.display=="block"){currFcnt=100;if(ie5){currFb.style.filter="alpha(opacity=100)";currFs.style.filter="alpha(opacity=50)"}else{currFb.style.MozOpacity=1;currFs.style.MozOpacity=0.5}hideAllScrollbars();currFb.style.display=currFs.style.display="block";changez(currFb);currFID=setInterval("sub_fadeout()",20)}else{currFb=null}}}function hidebox(a){if(w3c){d.getElementById(a+"_b").style.display="none";d.getElementById(a+"_s").style.display="none"}}function showbox(c){if(w3c){var b=d.getElementById(c+"_b");var a=d.getElementById(c+"_s");b.style.display="block";a.style.display="block";a.style.zIndex=++zdx;b.style.zIndex=++zdx;if(ns6){b.style.MozOpacity=1;a.style.MozOpacity=0.5}else{b.style.filter="alpha(opacity=100)";a.style.filter="alpha(opacity=50)"}changez(b)}}function changecontent(c,b){if(!document.getElementById(c+"_b").isExt){var a=document.getElementById(c+"_c");if(ns6){a.style.overflow="hidden"}a.innerHTML=b;if(ns6){a.style.overflow="block"}}else{document.getElementById(c+"_ifrm").src=b}}function movePopup(c,b,e){if(w3c){var a=document.getElementById(c+"_b");var c=document.getElementById(c+"_s");a.style.left=b+"px";c.style.left=b+8+"px";a.style.top=e+"px";c.style.top=e+8+"px"}}function resizePopup(a,c,b){if(w3c){if(d.getElementById(a+"_rs").rsEnable){d.gEl=d.getElementById;d.gEl(a+"_extWA").style.display="block";d.gEl(a+"_rs").style.left=Math.max(c,((ie5)?88:92))+"px";d.gEl(a+"_rs").style.top=Math.max(b,((ie5)?68:72))+"px";d.gEl(a+"_b").style.width=Math.max(c+((ie5)?12:8),100)+"px";d.gEl(a+"_b").style.height=Math.max(b+((ie5)?12:8),80)+"px";d.gEl(a+"_t").style.width=Math.max(c+((ie5)?4:3),((ns6)?95:92))+"px";d.gEl(a+"_btt").style.left=parseInt(d.gEl(a+"_t").style.width)-48+"px";d.gEl(a+"_s").style.width=Math.max(c+12,((ie5)?100:104))+"px";d.gEl(a+"_s").style.height=Math.max(b+((ie5)?12:13),((ie5)?80:86))+"px";d.gEl(a+"_c").style.width=Math.max(c-((ie5)?-5:5),((ie5)?92:87))+"px";d.gEl(a+"_c").style.height=Math.max(b-((ie5)?24:28),44)+"px";d.gEl(a+"_max").h=parseInt(d.gEl(a+"_b").style.height)}}}function hideAllScrollbars(){if(document.all){var a;for(i=0;i<cidlist.length;i++){a=cidlist[i];if(!document.getElementById(a+"_b").isExt){document.getElementById(a+"_c").style.overflow="hidden"}}}}function showAllScrollbars(){if(document.all){var a;for(i=0;i<cidlist.length;i++){a=cidlist[i];if(!document.getElementById(a+"_b").isExt){document.getElementById(a+"_c").style.overflow="auto"}}}}function sub_fadein(){currFcnt+=4;if(ie5){currFb.style.filter="alpha(opacity="+currFcnt+")";currFs.style.filter="alpha(opacity="+(currFcnt/2)+")"}else{currFb.style.MozOpacity=currFcnt/100;currFs.style.MozOpacity=(currFcnt/2)/100}if(currFcnt>=99){currFb.style.display=currFs.style.display="block";showAllScrollbars();currFb=null;clearInterval(currFID)}}function sub_fadeout(){currFcnt=currFcnt-4;if(ie5){currFb.style.filter="alpha(opacity="+currFcnt+")";currFs.style.filter="alpha(opacity="+(currFcnt/2)+")"}else{currFb.style.MozOpacity=currFcnt/100;currFs.style.MozOpacity=(currFcnt/2)/100}if(currFcnt<=0){currFb.style.display=currFs.style.display="none";showAllScrollbars();currFb=null;clearInterval(currFID)}}function minimize(){if(w3c){d.getElementById(this.cid+"_b").style.height=(ie5)?"28px":"24px";d.getElementById(this.cid+"_s").style.height="28px";d.getElementById(this.cid+"_c").style.display="none";d.getElementById(this.cid+"_rs").style.display="none";ns6bugfix()}}function restore(){if(w3c){d.getElementById(this.cid+"_b").style.height=this.h+"px";d.getElementById(this.cid+"_s").style.height=(ie5)?this.h+"px":this.h+5+"px";d.getElementById(this.cid+"_c").style.display="block";d.getElementById(this.cid+"_rs").style.display="block";ns6bugfix()}}function ns6bugfix(){if(navigator.userAgent.indexOf("Netscape/6")>0){setTimeout("self.resizeBy(0,1); self.resizeBy(0,-1);",100)}}function trackmouse(a){mx=(ie5)?event.clientX+d.body.scrollLeft:a.pageX;my=(ie5)?event.clientY+d.body.scrollTop:a.pageY;if(!ns6){movepopup()}if((currIDb!=null)||(currRS!=null)){return false}}function movepopup(){if((currIDb!=null)&&w3c){movePopup(currIDb.cid,mx+xoff,my+yoff)}if((currRS!=null)&&w3c){resizePopup(currRS.cid,mx+rsxoff,my+rsyoff)}return false}function stopRS(){d.getElementById(this.cid+"_extWA").style.display="none";currRS=null}function startRS(a){var c=(ie5)?event.clientX+d.body.scrollLeft:a.pageX;var b=(ie5)?event.clientY+d.body.scrollTop:a.pageY;rsxoff=parseInt(this.style.left)-c;rsyoff=parseInt(this.style.top)-b;currRS=this;if(ns6){d.getElementById(this.cid+"_c").style.overflow="hidden"}return false}function changez(a){var b=(a!=null)?a:this;if(oldac!=null){d.getElementById(oldac.cid+"_t").style.backgroundColor=oldac.inactivecolor}if(ns6){d.getElementById(b.cid+"_c").style.overflow="auto"}oldac=b;d.getElementById(b.cid+"_t").style.backgroundColor=b.activecolor;d.getElementById(b.cid+"_s").style.zIndex=++zdx;b.style.zIndex=++zdx;d.getElementById(b.cid+"_rs").style.zIndex=++zdx}function stopdrag(){currIDb=null;document.getElementById(this.cid+"_extWA").style.display="none";ns6bugfix()}function grab_id(a){var c=(ie5)?event.clientX+d.body.scrollLeft:a.pageX;var b=(ie5)?event.clientY+d.body.scrollTop:a.pageY;xoff=parseInt(d.getElementById(this.cid+"_b").style.left)-c;yoff=parseInt(d.getElementById(this.cid+"_b").style.top)-b;currIDb=d.getElementById(this.cid+"_b");currIDs=d.getElementById(this.cid+"_s");d.getElementById(this.cid+"_extWA").style.display="block";return false}function subBox(b,j,c,f,a,g){var e=d.createElement("div");e.setAttribute("id",g);e.style.position="absolute";e.style.left=b+"px";e.style.top=j+"px";e.style.width=c+"px";e.style.height=f+"px";if(a!=""){e.style.backgroundColor=a}e.style.visibility="visible";e.style.padding="0px";return e}function get_cookie(a){var b=a+"=";var c="";if(d.cookie.length>0){offset=d.cookie.indexOf(b);if(offset!=-1){offset+=b.length;end=d.cookie.indexOf(";",offset);if(end==-1){end=d.cookie.length}c=unescape(d.cookie.substring(offset,end))}}return c}function popUp(D,C,E,S,f,s,V,a,L,z,N,R,P,u,g,W,K,O,I,c,j){var n=false;if(j){if(get_cookie(f)==""){n=true;d.cookie=f+"=yes"}}else{n=true}if(n){if(w3c){cidlist[cidlist.length]=f;E=Math.max(E,100);S=Math.max(S,80);var B=new subBox(E-((ie5)?12:8),S-((ie5)?12:8),7,7,"",f+"_rs");if(O){B.innerHTML='<img src="resize.gif" width="7" height="7">';B.style.cursor="move"}B.rsEnable=O;var Q=(ie5)?E:E+4;var b=(ie5)?S:S+6;var A=new subBox(D+8,C+8,Q,b,g,f+"_s");if(ie5){A.style.filter="alpha(opacity=50)"}else{A.style.MozOpacity=0.5}A.style.zIndex=++zdx;var U=new subBox(D,C,E,S,P,f+"_b");U.style.display="block";U.style.borderStyle="outset";U.style.borderWidth="2px";U.style.borderColor=P;U.style.zIndex=++zdx;Q=(ie5)?E-8:E-5;b=(ie5)?S+4:S-4;var T=new subBox(2,2,Q,20,N,f+"_t");T.style.overflow="hidden";T.style.cursor="default";var J=(O)?'<img src="min.gif" width="16" height="16" id="'+f+'_min"><img src="max.gif" width="16" height="16"  id="'+f+'_max">':"";T.innerHTML='<span style="position:absolute; left:3px; top:1px; font:bold 10pt sans-serif; color:'+R+'; height:18px; overflow:hidden; clip-height:16px;">'+z+'</span><div id="'+f+'_btt" style="position:absolute; width:48px; height:16px; left:'+(Q-48)+'px; top:2px; text-align:right">'+J+'<img src="close.gif" width="16" height="16" id="'+f+'_cls"></div>';Q=(ie5)?E-7:E-13;var k=new subBox(2,24,Q,S-36,V,f+"_c");k.style.borderColor=P;k.style.borderWidth="2px";if(c){k.innerHTML='<iframe id="'+f+'_ifrm" src="'+s+'" width="100%" height="100%"></iframe>';k.style.overflow="hidden"}else{if(ie5){k.style.scrollbarBaseColor=u}k.style.borderStyle="inset";k.style.overflow="auto";k.style.padding="0px 2px 0px 4px";k.innerHTML=s;k.style.font=L;k.style.color=a}var e=new subBox(2,24,0,0,"",f+"_extWA");e.style.display="none";e.style.width="100%";e.style.height="100%";U.appendChild(T);U.appendChild(k);U.appendChild(e);U.appendChild(B);d.body.appendChild(A);d.body.appendChild(U);d.gEl=d.getElementById;if(!W){hidebox(f)}var q=d.gEl(f+"_b");q.cid=f;q.isExt=(c)?true:false;var l=d.gEl(f+"_t");l.cid=f;if(O){var v=d.gEl(f+"_rs");v.cid=f;var m=d.gEl(f+"_min");m.cid=f;var H=d.gEl(f+"_max");H.h=S;H.cid=f;m.onclick=minimize;H.onclick=restore;v.onmousedown=startRS;v.onmouseup=stopRS}var o=d.gEl(f+"_cls");var M=d.gEl(f+"_extWA");q.activecolor=N;q.inactivecolor=u;if(oldac!=null){d.gEl(oldac.cid+"_t").style.backgroundColor=oldac.inactivecolor}oldac=q;o.onclick=new Function("hidebox('"+f+"');");q.onmousedown=function(){changez(this)};if(K){l.onmousedown=grab_id;l.onmouseup=stopdrag}}else{if(I){var r=new Date();r=r.getTime();var F=(c)?s:"";var p=(ns4)?"screenX="+D+",screenY="+C:"left="+D+",top="+C;var G=window.open(F,"abc"+r,"status=no,menubar=no,width="+E+",height="+S+",resizable="+((O)?"yes":"no")+",scrollbars=yes,"+p);if(!c){F="<html><head><title>"+z+'</title></head><body bgcolor="'+V+'"><font style="font:'+L+"; color:"+a+'">'+s+"</font></body></html>";G.document.write(F);G.document.close()}}}}}if(ns6){setInterval("movepopup()",40)}if(w3c){d.onmousemove=trackmouse;d.onmouseup=new Function("currRS=null")};