<!--

function emailvalidation(entered, alertbox) {

with (entered) {

	apos=value.indexOf("@"); 
	dotpos=value.lastIndexOf(".");
	lastpos=value.length-1;
	if (apos<1 || dotpos-apos<2 || lastpos-dotpos>3 || lastpos-dotpos<2) {
		if (alertbox) {
			alert(alertbox);
		}
		return false;
	} else {
		return true;
	}
}
}


function integervalidation(entered, alertbox) {

with (entered) {

	if ((parseInt(value)) && (value.length > 0)) {
		return true
	} else {
		if (alertbox!="") {
			alert(alertbox);
		} 
		return false;
	}
}
}


function postcodevalidation(entered, alertbox) {

with (entered) {

	if (value.length==4) {
		return true
	} else {
		if (alertbox!="") {
			alert(alertbox);
		} 
		return false;
	}
}
}


function emptyvalidation(entered, alertbox) {

	with (entered) {
		if (value==null || value=="") {
			if (alertbox!="") {
				alert(alertbox);
			}
			return false;
		} else {
			return true;
		}
	}	
}


function shoutvalidation(entered) {

	with(entered) {
		if (value.length>150) {
			alert("Niet meer dan 150 karakters ingeven aub !!")
			return false
		} else if (value.length<1) {
			alert("Gelieve een bericht te typen !!")
			return false
		} else {
			return true
 		}

	}
}


function mailingformvalidation(thisform) {

with (thisform) {

if (emptyvalidation(voornaam,"Gelieve uw voornaam in te geven!")==false) {voornaam.focus(); return false;};

if (emailvalidation(email,"Gelieve een correct email adres in te geven!")==false) {email.focus(); return false;};

if (emptyvalidation(who,"Gelieve een winkel te selecteren die U wenst te contacteren!")==false) {who.focus(); return false;};

if (emptyvalidation(vraag,"Gelieve uw vraag te stellen!")==false) {vraag.focus(); return false;};

}
}

function shoutformvalidation(thisform) {

with (thisform) {

if (shoutvalidation(bericht)==false) {bericht.focus(); return false;};

}
}


function persbegmailform(thisform) {

with (thisform) {

if (emptyvalidation(naam,"Gelieve uw naam in te geven!")==false) {naam.focus(); return false;};
if (emptyvalidation(voornaam,"Gelieve uw voornaam in te geven!")==false) {voornaam.focus(); return false;};

if (emptyvalidation(adres,"Gelieve uw adres in te geven!")==false) {adres.focus(); return false;};
if (emptyvalidation(huisnr,"Gelieve uw huisnr in te geven!")==false) {huisnr.focus(); return false;};
if (emptyvalidation(postcode,"Gelieve uw postcode in te geven!")==false) {postcode.focus(); return false;};
if (emptyvalidation(woonplaats,"Gelieve uw woonplaats in te geven!")==false) {woonplaats.focus(); return false;};
if (emptyvalidation(land,"Gelieve uw land in te geven!")==false) {land.focus(); return false;};

if (emailvalidation(email,"Gelieve een correct email adres in te geven!")==false) {email.focus(); return false;};

if (emptyvalidation(v1,"Gelieve onze 1e vraag in te geven!")==false) {v1.focus(); return false;};
if (emptyvalidation(v2,"Gelieve onze 2e vraag in te geven!")==false) {v2.focus(); return false;};


}
}


function aanbiedingform(thisform) {

with (thisform) {

if (emptyvalidation(naam,"Gelieve uw naam in te geven!")==false) {naam.focus(); return false;};
if (emptyvalidation(voornaam,"Gelieve uw voornaam in te geven!")==false) {voornaam.focus(); return false;};

if (emptyvalidation(adres,"Gelieve uw adres in te geven!")==false) {adres.focus(); return false;};
if (emptyvalidation(huisnr,"Gelieve uw huisnr in te geven!")==false) {huisnr.focus(); return false;};
if (emptyvalidation(postcode,"Gelieve uw postcode in te geven!")==false) {postcode.focus(); return false;};
if (emptyvalidation(woonplaats,"Gelieve uw woonplaats in te geven!")==false) {woonplaats.focus(); return false;};
if (emptyvalidation(land,"Gelieve uw land in te geven!")==false) {land.focus(); return false;};

if (emailvalidation(email,"Gelieve een correct email adres in te geven!")==false) {email.focus(); return false;};

if (emptyvalidation(jaar,"Gelieve uw geboortejaar op te geven.")==false) {jaar.focus(); return false;};
if (emptyvalidation(jaar,"Gelieve uw geboortemaand op te geven.")==false) {maand.focus(); return false;};
if (emptyvalidation(jaar,"Gelieve uw geboortedag op te geven.")==false) {dag.focus(); return false;};
if (emptyvalidation(schoenmaat,"Gelieve uw schoenmaat op te geven.")==false) {schoenmaat.focus(); return false;};


}
}



-->
