function evalForm(){
	var iResult = 1;
	var thisForm = document.forms['inputform'];
	var entry = thisForm.email.value;

	if (iResult == 1){
		if(thisForm.navn.value == ""){
			alert("Du har ikke indtastet dit navn.");
			thisForm.navn.focus();
			iResult = 0;
		}
	}
	if (iResult == 1){
		if(thisForm.adresse.value == ""){
			alert("Du har ikke indtastet din adresse.");
			thisForm.adresse.focus();
			iResult = 0;
		}
	}

	if (iResult == 1){
		if(thisForm.postnr.value == ""){
			alert("Du har ikke indtastet dit postnr.");
			thisForm.postnr.focus();
			iResult = 0;
		}
	}
	if (iResult == 1){
		if(thisForm.email.value == ""){
			alert("Du har ikke indtastet din e-mail adresse.");
			thisForm.email.focus();
			iResult = 0;
		}
	}

	if (iResult == 1){
	    if (entry.indexOf(" ") != -1){
		    alert("Din e-mail kan ikke indeholde et mellemrum");
			thisForm.email.focus();
			iResult = 0;
		}
	}
	if (iResult == 1){
	    if (entry.indexOf("@") == -1){
		    alert("Din e-mail indeholder ikke et @");
			thisForm.email.focus();
			iResult = 0;
		}
	}
	if (iResult == 1){
	    if (entry.indexOf("@") == 0){
		    alert("@ kan ikke stå først i din e-mail");
			thisForm.email.focus();
			iResult = 0;
		}
	}
	if (iResult == 1){
	    if (entry.indexOf("@") == (entry.length-1)){
		    alert("@ kan ikke stå sidst i din email");
			thisForm.email.focus();
			iResult = 0;
		}
	}

	domain = entry.substring(entry.indexOf("@") + 1, entry.length);

	if (iResult == 1){
	    if (domain.indexOf(".") == -1){
		    alert("Domænet indeholder ikke et punktum");
			thisForm.email.focus();
			iResult = 0;
		}
	}
	if (iResult == 1){
	    if (domain.indexOf(".") == 0){
		    alert("Et punktum kan ikke stå først i din e-mail");
			thisForm.email.focus();
			iResult = 0;
		}
	}
	if (iResult == 1){
	    if (domain.indexOf(".") == (domain.length-1)){
		    alert("Et punktum kan ikke stå sidst i din e-mail");
			thisForm.email.focus();
			iResult = 0;
		}
	}

	if (iResult){
		thisForm.submit();
	}
}

