

/***************************
* Select funktion til tt_news cat-menu
****************************/
function Go (select) {
  var wert = select.options[select.options.selectedIndex].value;
  if (wert == "leer") {
    select.form.reset();
    return;
    } 
  else 
         {
       location.href = wert;
       }
}

/******************************
*  Åbner external links i nyt vindue
******************************/
function externalLinks() {
 if (!document.getElementsByTagName) return;
 var anchors = document.getElementsByTagName("a");
 for (var i=0; i<anchors.length; i++) {
   var anchor = anchors[i];
   if (anchor.getAttribute("href") &&
      anchor.getAttribute("class") == "external-link-new-window" ||
      anchor.getAttribute("class") == "internal-link-new-window" ||
      anchor.getAttribute("class") == "download")
     anchor.target = "_blank";
 }
}

// window.onload doesn't work in IE6 and IE7
// instead, IE supports an attribute called defer in its script tag
// which will have script loading deferred until the DOM has
// been loaded. This script is loaded though that tag.
//
// so, IE: deferred load of this script, then call externalLinks() immediately
// others: immediate load of this script, deferred call of externalLinks() through window.onload

var IE = /*@cc_on!@*/false;

if(IE) {
    externalLinks();
} else {
    window.onload = externalLinks();
}

