isOldIE=/MSIE (5.5|6.)/i.test(navigator.userAgent);
base=document.getElementsByTagName("base")[0].href;
try{
imgRoot="layout/"+stdLan+"/admin/images/";
}
catch(e){
imgRoot="layout/dk/admin/images/";
}
function cancelEvent(e){
var e=e||window.event;
if(e.preventDefault){
e.preventDefault();
}
if(e.stopPropagation){
e.stopPropagation();
}
if(e.stop){
e.stop();
}
if(document.all&&e.keyCode){
try{
e.keyCode=0;
}
catch(e){
}
}
e.cancelBubble=true;
e.returnValue=false;
}
function cancelSelection(e){
var e=e||window.event;
var _3=e.srcElement||e.target;
if(!_3||(_3.tagName!="INPUT"&&_3.tagName!="TEXTAREA")){
cancelEvent(e);
}
}
menu_isOpen=null;
menu_doClose=false;
function openMenu(_4){
if(menu_isOpen==_4){
closeMenu();
return false;
}else{
if(menu_isOpen){
closeMenu();
}
}
var _5=document.getElementById(_4);
_5.style.display="block";
_5.style.visibility="hidden";
menu_isOpen=_4;
var _6=_5.offsetLeft+_5.offsetWidth+2;
while(_5=_5.offsetParent){
_6+=_5.offsetLeft;
}
var w=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth;
if(_6>w){
document.getElementById(_4).style.left=(w-_6)+"px";
}
document.getElementById(_4).style.visibility="visible";
var _8=document.getElementsByTagName("iframe");
if(isOldIE){
var _9=document.getElementsByTagName("select");
var i=_9.length;
var j=i;
if(i>0){
do{
_9[j-i].style.visibility="hidden";
}while(--i);
}
var i=_8.length;
var j=i;
if(i>0){
do{
try{
var _9=_8[j-i].contentWindow.document.getElementsByTagName("select");
var m=_9.length;
var n=m;
if(m>0){
do{
_9[n-m].style.visibility="hidden";
}while(--m);
}
}
catch(e){
}
}while(--i);
}
}
var i=_8.length;
var j=i;
if(document.attachEvent){
document.attachEvent("onclick",closeMenu);
if(i>0){
do{
try{
_8[j-i].contentWindow.document.attachEvent("onclick",window.closeMenu);
}
catch(e){
}
}while(--i);
}
}else{
document.addEventListener("click",closeMenu,false);
if(i>0){
do{
try{
_8[j-i].contentWindow.document.addEventListener("click",window.closeMenu,false);
}
catch(e){
}
}while(--i);
}
}
menu_doClose=false;
}
function closeMenu(){
if(!menu_doClose){
menu_doClose=true;
return false;
}
document.getElementById(menu_isOpen).style.display="none";
menu_isOpen=null;
var _e=document.getElementsByTagName("iframe");
if(/MSIE (5.5|6.)/i.test(navigator.userAgent)){
var _f=document.getElementsByTagName("select");
var i=_f.length;
var j=i;
if(i>0){
do{
_f[j-i].style.visibility="visible";
}while(--i);
}
var i=_e.length;
var j=i;
if(i>0){
do{
try{
var _f=_e[j-i].contentWindow.document.getElementsByTagName("select");
var m=_f.length;
var n=m;
if(m>0){
do{
_f[n-m].style.visibility="visible";
}while(--m);
}
}
catch(e){
}
}while(--i);
}
}
var i=_e.length;
var j=i;
if(document.detachEvent){
document.detachEvent("onclick",closeMenu);
if(i>0){
do{
try{
_e[j-i].contentWindow.document.detachEvent("onclick",window.closeMenu);
}
catch(e){
}
}while(--i);
}
}else{
document.removeEventListener("click",closeMenu,false);
if(i>0){
do{
try{
_e[j-i].contentWindow.document.removeEventListener("click",window.closeMenu,false);
}
catch(e){
}
}while(--i);
}
}
document.getElementById("contents").style.overflow="auto";
}
menuScroller=null;
function initMenu(_14){
var tmp=document.getElementById(_14);
if(menu_isOpen!=_14){
var ss=tmp.style;
ss.visibility="hidden";
ss.display="block";
}
var h=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight;
var _14=tmp.firstChild;
while(_14.tagName=="IMG"){
_14=_14.nextSibling;
}
_14.style.height="auto";
if(_14.offsetHeight>h-50){
var ss=_14.style;
ss.height=(h-100)+"px";
ss.overflow="hidden";
if(!_14.init){
var img=document.createElement("img");
var ss=img.style;
img.alt="";
ss.display="block";
ss.width=_14.offsetWidth+"px";
ss.height="14px";
var top=img.cloneNode(false);
top.src="layout/dk/admin/images/scroll_up.jpg";
var _1a=img.cloneNode(false);
_1a.src="layout/dk/admin/images/scroll_down.jpg";
var id=tmp.id;
if(document.attachEvent){
top.attachEvent("onmouseover",function(){
menuScroller=setInterval(function(){
menuScroll(id,-2);
},10);
});
top.attachEvent("onmouseout",function(){
clearInterval(menuScroller);
});
_1a.attachEvent("onmouseover",function(){
menuScroller=setInterval(function(){
menuScroll(id,2);
},10);
});
_1a.attachEvent("onmouseout",function(){
clearInterval(menuScroller);
});
}else{
top.addEventListener("mouseover",function(){
menuScroller=setInterval(function(){
menuScroll(id,-2);
},10);
},false);
top.addEventListener("mouseout",function(){
clearInterval(menuScroller);
},false);
_1a.addEventListener("mouseover",function(){
menuScroller=setInterval(function(){
menuScroll(id,2);
},10);
},false);
_1a.addEventListener("mouseout",function(){
clearInterval(menuScroller);
},false);
}
tmp.insertBefore(top,_14);
tmp.appendChild(_1a);
_14.init=true;
img=null;
top=null;
_1a=null;
}
}
if(menu_isOpen!=_14){
var ss=tmp.style;
ss.display="none";
ss.visibility="visible";
}
tmp=null;
_14=null;
}
function menuScroll(_1c,_1d){
document.getElementById(_1c).childNodes[1].scrollTop+=_1d;
}
helpTimer=null;
function help(_1e,txt){
if(document.getElementById("help_text")){
helpClose();
}
var div=document.createElement("div");
var _21=document.getElementsByTagName("base")[0].href;
var _22=div.cloneNode(false);
_22.id="help_text";
var top=div.cloneNode(false);
var ss=top.style;
ss.width="143px";
ss.height="10px";
if(!isOldIE){
ss.backgroundImage="url("+imgRoot+"help/help_top.png)";
}else{
ss.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\""+_21+imgRoot+"help/help_top.png\",sizingMethod=\"noscale\")";
}
var _25=div.cloneNode(false);
var ss=_25.style;
ss.width="143px";
ss.height="25px";
if(!isOldIE){
ss.backgroundImage="url("+imgRoot+"help/help_bottom.png)";
}else{
ss.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\""+_21+imgRoot+"help/help_bottom.png\",sizingMethod=\"noscale\")";
}
var _26=div.cloneNode(false);
var ss=_26.style;
ss.width="123px";
ss.padding="0px 10px";
ss.fontSize="9px";
if(!isOldIE){
ss.backgroundImage="url("+imgRoot+"help/help_bg.png)";
}else{
ss.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\""+_21+imgRoot+"help/help_bg.png\",sizingMethod=\"scale\")";
}
_26.innerHTML=txt;
_22.appendChild(top);
top=null;
_22.appendChild(_26);
_26=null;
_22.appendChild(_25);
_25=null;
div=null;
var ss=_22.style;
ss.left="0px";
ss.top="0px";
ss.position="absolute";
ss.zIndex="10000000000000000";
ss.visibility="hidden";
_1e.parentNode.appendChild(_22);
ss.left=Math.round((_1e.offsetLeft+_1e.offsetWidth/2-_22.offsetWidth/2))+"px";
ss.top=(_1e.offsetTop-_22.offsetHeight-2)+"px";
ss.visibility="visible";
_22=null;
_1e=null;
}
function helpClose(){
var _27=document.getElementById("help_text");
if(!_27){
return false;
}
_27.parentNode.removeChild(_27);
clearTimeout(helpTimer);
}

