function chk()
{  
	window.top.location="usrReg.php";
}
function trimString (str)
{
	str = this != window? this : str;
	return str.replace(/^\s+/g, '').replace(/\s+$/g, '');
}
function isCharsInBag (s, bag)
{  
    var i;
    for (i = 0; i < s.length; i++)
    {   
       
        var c = s.charAt(i);
        if (bag.indexOf(c) == -1) return false;
    }
    return true;
}	
function chkadd()
       {
		   
		    if(trimString(document.frmLogin.enounid.value)=="")
                        {
                                alert( "Enoun id should not be blank" );
                                document.frmLogin.enounid.focus();
                                  return false;
                        }
            if (!isCharsInBag(document.frmLogin.enounid.value, "_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890" ))
		           {
			         alert("Invalid characters in\"Enoun id \" field " );
			         document.frmLogin.enounid.focus();
			         return false;
                }
         
						
				if(trimString(document.frmLogin.password.value)=="")
                        {
                                alert( "Password should not be blank" );
                                document.frmLogin.password.focus();
                                  return false;
                         }
				
return true;
	   }