// JavaScript Document

function CheckBlankValue(mes,obj)
	{
		if(obj.value=="")
		{
			obj.focus();
			alert(mes);
			return false;
		}
	}
	
function checkNumber(obj,str){
	  userName = obj;
	  len = obj.length;
	  var valid = "1234567890"
	  for(i = 0 ;i<len;i++)
	  {
			j = i +1
			strValue = obj.substring(i,i+1)
			if(valid.indexOf(strValue) == "-1")
			{
				alert("Only numbers are accepted in " + str + " box");
				return false;
			}
	  }
 }
 
 function check_email(obj)
{
	 if ((/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(obj.value)) == false)
 		{
			alert("Please enter a valid email address")
		    obj.focus();
		    obj.select();
			return false;
		}
}
