﻿function clean(what) 
{
	var content=document.getElementById(what).value.substr(0,6);
	if (content=="insert") 
	{ 
	document.getElementById(what).value="";
	document.getElementById(what).style.color="black";
	}
}

function validation(form)
	{
		// Overall variable contains validation value
		
		var ok = true;
		
		
		// Check all different input values
		
		
		if ((document.form.subject.value=="")||(document.form.subject.value=="select a subject!")) 
		{ 
		document.form.subject.style.color="red";
		document.form.subject.value="insert a subject!";
		ok=false;
		}
		
		
		
		
	
		
		if (ok)	form.submit();

		}
