//Image preloader
imageSource = new Array (
	"images/spacer.gif"
);

imageList = new Array ();

for (counter in imageSource) {
    imageList[counter] = new Image();
    imageList[counter].src = imageSource[counter];
}

//Remove outline around links
function removeFocusOnAllLinks(){
for(var i=0 ; i < document.links.length ; i++)
document.links[i].onfocus=blurLink;
}

function blurLink() {
if (this.blur) this.blur();
}

window.onload=removeFocusOnAllLinks;

//Function for contact form
function funcfrmContact() {
	if (document.frmContact.Kontaktperson.value == "") {
		alert('Du måste ange kontaktperson!');
		document.frmContact.Kontaktperson.focus();
		return false;
	}
	else if (document.frmContact.Epostadress.value == "") {
		alert('Du måste ange din epostadress!');
		document.frmContact.Epostadress.focus();
		return false;
	}
	else if (document.frmContact.Meddelande.value == "") {
		alert('Du måste skriva ett meddelande!');
		document.frmContact.Meddelande.focus();
		return false;
	}
	document.frmContact.email.value = document.frmContact.Epostadress.value;
	document.frmContact.realname.value = document.frmContact.Kontaktperson.value;
	document.frmContact.submit();
}
