	/*
	Copyright notice:
	These Javascripts are made on behalf of Mrsh AB (www.mrsh.se) by Fredrik Nevenius, Nevenius AB (www.nevenius.se and www.webbyroo.com) mainly for
	functional use as popops, image resizing and condition checks. As Javascript is open source
	and easily can be copied or manipulated for use with other sites, and there really is no technical solution to
	hide the source code for the general public, you may use or manipulate the scripts for your own purposes
	if you mention the author and the owner and link to our respective sites in the script source. 
	We would like to thank the authors of other scripts that gave us the inspiration to write our own.
	
	Last javascript was updated August 26, 2008
	*/
	function winBRopen(theURL, Name, popW, popH, scroll)
	{
		var winleft = (screen.width - popW) / 2;
		var winUp = (screen.height - popH) / 2;
		winProp = 'width='+popW+',height='+popH+',left='+winleft+',top='+winUp+',scrollbars='+scroll+',resizable'
		Win = window.open(theURL, Name, winProp)
		if (parseInt(navigator.appVersion) >= 4) 
		{ 
			Win.window.focus(); 
		}
	}
	function waitscript()
	{
		document.getElementById("wait1").style.visibility = "hidden";
	}
	function showunderline(divid)
	{
		document.getElementById(''+divid+'').style.visibility = "visible";
	}
	function hideunderline(divid)
	{
		document.getElementById(''+divid+'').style.visibility = "hidden";
	}
	function shownormalprice()
	{
		document.getElementById('normalcart').style.visibility = "visible";
		document.getElementById('fmcart').style.visibility = "hidden";
		document.getElementById('ducart3').style.visibility = "hidden";
		document.getElementById('ducart6').style.visibility = "hidden";
	}
	function showfmprice()
	{
		document.getElementById('fmcart').style.visibility = "visible";
		document.getElementById('normalcart').style.visibility = "hidden";
		document.getElementById('ducart3').style.visibility = "hidden";
		document.getElementById('ducart6').style.visibility = "hidden";
		if (document.personuppgifter.levfornamn.value != '' || document.personuppgifter.levefternamn.value != '' || document.personuppgifter.levadress.value != ''  || document.personuppgifter.levpostnr.value != ''  || document.personuppgifter.levort.value != '')
		{
			alert("Vid faktura levererar vi endast till folkbokföringsadressen");
		}
	}
	function showduprice3()
	{
		document.getElementById('fmcart').style.visibility = "hidden";
		document.getElementById('normalcart').style.visibility = "hidden";
		document.getElementById('ducart3').style.visibility = "visible";
		document.getElementById('ducart6').style.visibility = "hidden";
		if (document.personuppgifter.levfornamn.value != '' || document.personuppgifter.levefternamn.value != '' || document.personuppgifter.levadress.value != ''  || document.personuppgifter.levpostnr.value != ''  || document.personuppgifter.levort.value != '')
		{
			alert("Vid dela upp betalningen levererar vi endast till folkbokföringsadressen");
		}
	}
	function showduprice6()
	{
		document.getElementById('fmcart').style.visibility = "hidden";
		document.getElementById('normalcart').style.visibility = "hidden";
		document.getElementById('ducart3').style.visibility = "hidden";
		document.getElementById('ducart6').style.visibility = "visible";
		if (document.personuppgifter.levfornamn.value != '' || document.personuppgifter.levefternamn.value != '' || document.personuppgifter.levadress.value != ''  || document.personuppgifter.levpostnr.value != ''  || document.personuppgifter.levort.value != '')
		{
			alert("Vid dela upp betalningen levererar vi endast till folkbokföringsadressen");
		}
	}
	function go(where)
	{
		document.location = where;
	}
	function goblog(where)
	{
		window.open(where, '_blog');
	}
	function showbig(divid)
	{
		var bigbildid = "big" + divid
		var thumbbildid = "thumb" + divid
		var info = "info" + divid
		//prompt(bigbildid);
		document.getElementById(thumbbildid).style.width = "1px";
		document.getElementById(thumbbildid).style.height = "1px";
		document.getElementById(thumbbildid).style.visibility = "hidden";
		document.getElementById(info).style.width = "230px";
		document.getElementById(bigbildid).style.width = "160px";
		document.getElementById(bigbildid).style.height = "100%";
		document.getElementById(bigbildid).style.visibility = "visible";
	}
	function showthumb(divid)
	{
		var bigbildid = 'big' + divid
		var thumbbildid = 'thumb' + divid
		var info = "info" + divid
		document.getElementById(bigbildid).style.width = "1px";
		document.getElementById(bigbildid).style.height = "1px";
		document.getElementById(bigbildid).style.visibility = "hidden";
		document.getElementById(info).style.width = "395px";
		document.getElementById(thumbbildid).style.width = "160px";
		document.getElementById(thumbbildid).style.height = "100%";
		document.getElementById(thumbbildid).style.visibility = "visible";
	}
	function MM_openBrWindow(theURL,winName,features)
	{
		window.open(theURL,winName,features);
	}
	function loadFragmentInToElement(fragment_url, element_id, loadafter_url, loadafter_id)
	{
		var xmlhttp=false;
		if (!xmlhttp && typeof XMLHttpRequest!='undefined')
		{
			xmlhttp = new XMLHttpRequest();
		}
		var element = document.getElementById(element_id);
		//element.innerHTML = '<p><em>Loading ...</em></p>';
		xmlhttp.open("GET", fragment_url, true);
		xmlhttp.onreadystatechange = function()
			{
				if (xmlhttp.readyState == 4 && xmlhttp.status == 200)
				{
					element.innerHTML = xmlhttp.responseText;
					if(loadafter_id)
					{
						loadFragmentInToElement(loadafter_url, loadafter_id);
 			   		}
 		  		 }
 	   		}
 	   xmlhttp.send(null);
    }