function popWin(sUrl,iWidth,iHeight,sWindow,iScrollbar) {

	if (iScrollbar == 1) {
		iScroll = 1
	} else {
		iScroll = 0
	}

    var iLeftPos = Math.round((screen.width-iWidth)/2);
    var iTopPos = Math.round((screen.height-iHeight)/2);
    popwin = window.open(sUrl,sWindow,'width='+iWidth+', height='+iHeight+',top='+iTopPos+',left='+iLeftPos+',scrollbars='+iScroll);
}

function sendfile(iID) {
	popWin('/send_file.asp?intID='+iID,50,50,'file_download')
}

function goShow(iID) {
	if (document.getElementById('faq_'+iID).style.display == "none") {
		document.getElementById('faq_'+iID).style.display = "block";
	} else {
		document.getElementById('faq_'+iID).style.display = "none";
	}
}

function chkFAQForm() {

	if (document.formfaq.name.value == "") {
		alert("Du skal udfylde navn!");
		document.formfaq.name.focus();
		return false;
	}
	
	if (document.formfaq.email.value == "") {
		alert("Du skal udfylde e-mail adresse!");
		document.formfaq.email.focus();
		return false;
	}
	
	if (document.formfaq.title.value == "") {
		alert("Du skal udfylde emne!");
		document.formfaq.title.focus();
		return false;
	}
	
	if (document.formfaq.content.value == "") {
		alert("Du skal udfylde spørgsmål/kommentar!");
		document.formfaq.content.focus();
		return false;
	}
	
	document.formfaq.submit();
	
}