var menuHTML = ""; // menu format var menuOffsetLeft = 0; var menuOffsetTop = 20; var dropMenuWidth = 175; var maxOffsetLeft = 765-dropMenuWidth; // ajusted in setDim var maxOffsetLeftDef = 765-dropMenuWidth; var menuStart = "
"; // remember to include "id" in the top block element var menuEnd = "
"; var itemStart = ""; // remember to include nav in the container var itemEnd = ""; // Item format var gemtmenuColors = [ ['rgb(185,141,140)','rgb(109,44,48)','rgb(255,255,255)'], ['rgb(187,153,144)','rgb(133,110,76)','rgb(255,255,255)'], ['rgb(185,203,161)','rgb(130,143,87)','rgb(255,255,255)'], ['rgb(154,195,153)','rgb(75,130,73)','rgb(255,255,255)'], ['rgb(153,197,161)','rgb(68,132,108)','rgb(236,236,236)'], ['rgb(159,201,200)','rgb(70,134,134)','rgb(236,236,236)'], ['rgb(154,153,197)','rgb(39,46,101)','rgb(0,236,236)'], ['rgb(134,133,175)','rgb(48,78,114)','rgb(236,236,236)'], ['rgb(136,122,157)','rgb(66,40,105)','rgb(255,255,255)'], ['rgb(180,144,182)','rgb(110,50,112)','rgb(255,255,255)'], ['rgb(177,121,149)','rgb(113,49,86)','rgb(255,255,255)'], ['rgb(198,198,198)','rgb(153,153,153)','rgb(255,255,255)'] ]; var menuColors = [ ['rgb(185,141,140)','rgb(109,44,48)','rgb(255,255,255)'], ['rgb(187,153,144)','rgb(133,110,76)','rgb(255,255,255)'], ['rgb(185,203,161)','rgb(130,143,87)','rgb(255,255,255)'], ['rgb(154,195,153)','rgb(75,130,73)','rgb(236,236,236)'], ['rgb(153,197,161)','rgb(68,132,108)','rgb(236,236,236)'], ['rgb(159,201,200)','rgb(70,134,134)','rgb(236,236,236)'], ['rgb(134,133,175)','rgb(48,78,114)','rgb(255,255,255)'], ['rgb(154,153,197)','rgb(39,46,101)','rgb(255,255,255)'], ['rgb(180,144,182)','rgb(110,50,112)','rgb(255,255,255)'], ['rgb(177,121,149)','rgb(113,49,86)','rgb(255,255,255)'], ['rgb(136,122,157)','rgb(66,40,105)','rgb(255,255,255)'], ['rgb(198,198,198)','rgb(153,153,153)','rgb(255,255,255)'] ]; var gemtmenuColorsIndex = [ ['rgb(185,141,140)','rgb(109,44,48)','rgb(255,255,255)'], ['rgb(187,153,144)','rgb(133,110,76)','rgb(255,255,255)'], ['rgb(185,203,161)','rgb(130,143,87)','rgb(255,255,255)'], ['rgb(154,195,153)','rgb(75,130,73)','rgb(255,255,255)'], ['rgb(153,197,161)','rgb(68,132,108)','rgb(236,236,236)'], ['rgb(159,201,200)','rgb(70,134,134)','rgb(236,236,236)'], ['rgb(134,133,175)','rgb(48,78,114)','rgb(236,236,236)'], ['rgb(154,153,197)','rgb(39,46,101)','rgb(236,236,236)'], ['rgb(132,133,177)','rgb(66,40,105)','rgb(255,255,255)'], ['rgb(180,144,182)','rgb(110,50,112)','rgb(255,255,255)'], ['rgb(185,141,142)','rgb(113,49,86)','rgb(255,255,255)'] ]; var menuColorsIndex = [ ['rgb(185,141,140)','rgb(109,44,48)','rgb(255,255,255)'], ['rgb(187,153,144)','rgb(133,110,76)','rgb(255,255,255)'], ['rgb(185,203,161)','rgb(130,143,87)','rgb(255,255,255)'], ['rgb(154,195,153)','rgb(75,130,73)','rgb(255,255,255)'], ['rgb(153,197,161)','rgb(68,132,108)','rgb(236,236,236)'], ['rgb(159,201,200)','rgb(70,134,134)','rgb(236,236,236)'], ['rgb(134,133,175)','rgb(48,78,114)','rgb(236,236,236)'], ['rgb(154,153,197)','rgb(39,46,101)','rgb(236,236,236)'], ['rgb(132,133,177)','rgb(66,40,105)','rgb(255,255,255)'], ['rgb(180,144,182)','rgb(110,50,112)','rgb(255,255,255)'], ['rgb(185,141,142)','rgb(113,49,86)','rgb(255,255,255)'] ]; var activeTopLevel; // Make the menus var z = 0; // ValidUrl=0; // txtValue = ""; ValidUrl="0"; for (var i=0; i < menuItems.length; i++) { if (menuHTML != "" && menuItems[i][0] == 0) menuHTML += menuEnd; if (menuItems[i][0] == 0) { menuHTML += menuStart.replace("id","id=\"menuID" + z + "\""); z++ } else { ValidUrl=0; if(menuItems[i][1]=="Log af") ValidUrl="1"; else ValidUrl="0"; // txtValue += menuItems[i][1] + " -- " + ValidUrl; if(menuItems[i][3]!="1"){ if (document.all) menuHTML += itemStart.replace("nav","onmouseover=\"delayCloseMenu();this.style.backgroundColor=currentHoverColor;\" onmouseout=\"startCloseMenu();this.style.backgroundColor=currentTableColor;\" onclick=\"ok=" + ValidUrl + ";document.location.href='" + menuItems[i][2] + "'\""); else menuHTML += itemStart.replace("nav","onmouseover=\"delayCloseMenu();this.style.backgroundColor=currentHoverColor;this.style.cursor = 'pointer';\" onmouseout=\"startCloseMenu();this.style.backgroundColor=currentTableColor;\" onclick=\"ok=" + ValidUrl + ";document.location.href='" + menuItems[i][2] + "'\""); }else{ if (document.all) menuHTML += itemStart.replace("nav","onmouseover=\"delayCloseMenu();this.style.backgroundColor=currentHoverColor;\" onmouseout=\"startCloseMenu();this.style.backgroundColor=currentTableColor;\" onclick=\"ok=" + ValidUrl + ";window.open('" + menuItems[i][2] + "')\""); else menuHTML += itemStart.replace("nav","onmouseover=\"delayCloseMenu();this.style.backgroundColor=currentHoverColor;this.style.cursor = 'pointer';\" onmouseout=\"startCloseMenu();this.style.backgroundColor=currentTableColor;\" onclick=\"ok=" + ValidUrl + ";window.open('" + menuItems[i][2] + "')\""); } //menuHTML += ""; menuHTML += menuItems[i][1]; //menuHTML += ""; menuHTML += itemEnd; } } menuHTML += menuEnd; // alert(txtValue); // Menu controls var delayClose = null; var openMenuID= null; var currentHoverColor; var currentTableColor; function getObj(id) { var obj; if (document.all) obj = document.all[id]; else obj = document.getElementById(id); return obj; } function allwaysOnMenu() { if (allwaysOn!="") { if (allwaysOn.substring(0,1)=="0") ao = allwaysOn.substring(1,2) else ao = allwaysOn menunum = parseInt(ao) - 1; currentHoverColor = menuColors[ menunum ][1]; findObj("m" + menunum).style.backgroundColor = currentHoverColor; findObj("Mlink" + menunum).style.color = "rgb(255,255,255)"; } } function showMenu(menu,offsetTopUp) { var mID = menu; if (openMenuID != null) hideMenu(); currentTableColor = menuColors[mID][0]; currentHoverColor = menuColors[mID][1]; findObj("m" + mID).style.backgroundColor = currentHoverColor; findObj("Mlink" + mID).style.color = "rgb(255,255,255)"; var oLeft = getOffsetLeft("m" + mID) + (menuOffsetLeft-1); var oTop = getOffsetTop("m" + mID) + (menuOffsetTop-offsetTopUp); if (maxOffsetLeft < oLeft) oLeft = maxOffsetLeft; var mObj = findObj("menuID"+mID); with (mObj) { style.backgroundColor = currentTableColor; style.left = oLeft; style.top = oTop; style.visibility = "visible"; } openMenuID = mID; } function setActiveTopLevel(id) { currentHoverColor = menuColors[id][1]; findObj("m" + id).style.backgroundColor = currentHoverColor; findObj("Mlink" + id).style.color = "rgb(255,255,255)"; activeTopLevel = id; } function hideMenu() { if (delayClose || delayClose == 0) clearTimeout(delayClose); findObj("menuID"+openMenuID).style.visibility = "hidden"; var offColor; if (activeTopLevel != openMenuID) { offColor = menuColors[openMenuID][2]; if (typeof(allwaysOn)=="undefined") { findObj("m" + openMenuID).style.backgroundColor = offColor; if (openMenuID < 6) findObj("Mlink" + openMenuID).style.color = "rgb(97,97,97)"; else findObj("Mlink" + openMenuID).style.color = "rgb(102,102,102)"; } else { if (allwaysOn.substring(0,1)=="0") ao = allwaysOn.substring(1,2) else ao = allwaysOn if (parseInt(openMenuID) != (parseInt(ao)-1)) { findObj("m" + openMenuID).style.backgroundColor = offColor; if (openMenuID < 6) findObj("Mlink" + openMenuID).style.color = "rgb(97,97,97)"; else findObj("Mlink" + openMenuID).style.color = "rgb(102,102,102)"; } } } openMenuID = null; } function startCloseMenu() { delayClose = setTimeout("hideMenu()",200); } function delayCloseMenu() { if (delayClose || delayClose == 0) clearTimeout(delayClose); } function findObj(n, d) { // version 1.0, soren@araneum.dk, Litra B. // n: name or object id // d: document if left empty, can be used for finding objects in other frames etc. var p,i,x; if (!d) d=document; if ((p=n.indexOf("?"))>0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p); } if (!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i shadowLeftH) shadowLeftH = getHeight("rightContent"); with (findObj("ContentShadowRight")) { style.marginTop = -(shadowLeftM); style.height = (shadowLeftH); style.display = "block"; } shadowSet = true; } // // If screen height is to small if ((winHeight < 400) || (navigator.userAgent.indexOf('iPad') != -1) || (navigator.userAgent.indexOf('iPhone') != -1) || (navigator.userAgent.indexOf('iPod') != -1)) { with (findObj("body")) { style.overflow = "auto"; } with (findObj("scrollContent")) { style.display = "inline"; style.height = "100%"; } } // Small height end } // Sitemap var topNo = 0; function getSitemap() { var sitemapHTML = ""; var currentColor; ValidUrl="0"; for (var i=0; i < sitemapItems.length; i++) { if (sitemapItems[i][0] == 0) { currentColor = menuColorsIndex[topNo][1]; if (topNo > 0) sitemapHTML += ""; if (document.all) sitemapHTML += ""; sitemapHTML += "
\"Vis/skjul\"" + sitemapItems[i][1] + "

" else sitemapHTML += "
\"Vis/skjul\"" + sitemapItems[i][1] + "

" topNo++ } if (sitemapItems[i][0] == 1) { sitemapHTML += "" } if (sitemapItems[i][0] == 2) { sitemapHTML += "" } if (sitemapItems[i][0] == 3) { sitemapHTML += "" } } sitemapHTML += "
"; return sitemapHTML; } var rowShow = "table-row"; if (document.all) rowShow = "block" function showSitemap(what) { if (what == "all") { for (var i=0; i < topNo; i++) { findObj("sitemapR" + i).style.display = rowShow; findObj("smImg" + i).src ="/C12571460044841F/sitemapMinus.gif"; } } if (what == "none") { for (var i=0; i < topNo; i++) { findObj("sitemapR" + i).style.display = "none"; findObj("smImg" + i).src ="/C12571460044841F/sitemapPlus.gif"; } } if (what != "none" && what != "all") { if (findObj("sitemapR" + what).style.display == "none") findObj("sitemapR" + what).style.display = rowShow; else findObj("sitemapR" + what).style.display = "none"; obj = findObj("smImg" + what) if (obj.src.indexOf("/C12571460044841F/sitemapMinus.gif") > 0) obj.src ="/C12571460044841F/sitemapPlus.gif"; else obj.src ="/C12571460044841F/sitemapMinus.gif"; } } function openpopwin(url,wname,winWidth,winHeight) { var popwin if (wname=='') wname='nyt'; if (winWidth=='') winWidth=300; if (winHeight=='') winHeight=300; if (url=='') url='http:\/\/www.w3.org'; popwin=window.open(url,wname,'toolbar=no,copyhistory=no,location=no,directories=no,status=no,menubar=yes,scrollbars=yes,resizable=yes,width=' + winWidth + ',height=' + winHeight); if (popwin.focus!=null) { popwin.focus(); } } function toggleYear(chkObj) { var hideShow = rowShow; if (chkObj.checked) hideShow = "none"; findObj("year1").style.display = hideShow; findObj("year2").style.display = hideShow; }