function submitform( theform )
{
	if(theform.onsubmit())
	{
    		//this check triggers the validations
		theform.submit();
	}
}