function setVat(vat) {
  var url;
  url = window.location.pathname+"?incl_tax="+vat;
  window.location.href = url;
}

function openWin( windowURL, windowName, windowFeatures ) {
	return window.open( windowURL, windowName, windowFeatures ) ;
}

function changeImage(switchto)
{
  if(document.getElementById("biggraph")) {
    document.getElementById("biggraph").src=switchto;
  }
}

function visaArkiv() {
  if(document.getElementById("arkiv")) {
    if(document.getElementById("arkiv").style.display == "none") {
      document.getElementById("arkiv").style.display = "";
    } else {
      document.getElementById("arkiv").style.display = "none";
    }
  }
}

function changeperiod(fondid) {
  if(document.getElementById("sy") && document.getElementById("ey")) {
    var sy = document.getElementById("sy").options[document.getElementById("sy").selectedIndex].value;
    var ey = document.getElementById("ey").options[document.getElementById("ey").selectedIndex].value;
    changeImage('/graf.phtml?fond='+fondid+'&sy='+sy+'&ey='+ey);
  }
}