var ns4=document.layers?1:0
var ie4=document.all?1:0
var ns6=document.getElementById&&!document.all?1:0

if (ns4)
document.captureEvents(Event.KEYPRESS)
function checkKeyPress(e)
{

	if (document.login.userID.value.length > 0 && document.login.password.value.length > 0)
	{
		if (ns4||ns6)
		{
			if (e.which==13)
				{ checkLogin(); }
		}
		else if (ie4)
		{
			if (event.keyCode==13)
				{ checkLogin(); }
		}
	}


}

function checkLogin()
{
	if (document.login.password.value.length <= 0)
	{
		alert("Please enter your password");
		document.login.userID.focus();
	}
	if (document.login.userID.value.length <= 0)
	{
		alert("Please enter your UserID");
		document.login.userID.focus();
	}
	if (document.login.userID.value.length > 0 && document.login.password.value.length > 0)
	{
		document.login.submit();
	}

}

document.onkeypress = checkKeyPress
