jQuery(document).ready(function($) {
	$('form.emailform').submit(function() {
		var submitForm = true;
		
		$('form.emailform span.error').remove();
				
		$('form.emailform .verplicht').each(function() {
			if(!$(this).val()) {
				$(this).css({
							'background':'#ffa0a0',
							'border':'1px solid #ff5959'							
							});
				$(this).after('<span class="error">Dit veld is verplicht.</span>');
				
				submitForm = false;
			} else {
				$(this).css({
							'background':'',
							'border':''
							});
			}
		});
		if(!submitForm) {
			return false;
		}
	});
});
