function raiseError(s)
{
	document.form1.step.value = "1";
	alert(s)
    status = s
}

function checkAll()	//javascript for contact form
{
	if ( 
		(isEmpty(document.form1.name.value )) ||
		(isEmpty(document.form1.comment.value )) 		
		) 	
	{
       raiseError('NOTE: all fields marked with asterix *  are required')
	   return false;
    }

	if ( (!isEmail(document.form1.email.value)) || (isEmpty(document.form1.email.value)) )
	{
       raiseError('Email address is not valid')
	   return false;
    }
	return true;
}

function checkLogin()	//javascript for contact form
{
    if ( navigator.cookiesAreEnabled() ) 
    {
		if ( 
			(isEmpty(document.form1.username.value )) ||
			(isEmpty(document.form1.psword.value )) 		
			) 	
		{
    	   raiseError('NOTE: all fields marked with asterix *  are required')
		   return false;
    	}
		return true;
	}
	else
	{
      msg = "Cookies are not enabled on this browser! ";
      msg += "Please enable cookies in your browser. You will not be able to access ROME REPOSITORY system if your cookies are disabled.";
      window.alert( msg );
      return false;
	}
}


