<script type="text/javascript">
function validator() {
var username = document.getElementById('txtUserName').value;
var password = document.getElementById('txtPassword').value;
//alert(username+","+password);
if (username == 'admin' && password == '888888') {
alert('输入正确');
}
else {
alert('输入错误');
}
}*/
</script>
</head>
<body>
用户名:<input id="txtUserName" type="text" /><br />
密码:<input id="txtPassword" type="text" /><br />
<input id="Button1" type="button" value="登录" onclick="validator();" />
</body>
</html>