O que ha de errado no meu codigo???
<html>
<head>
<script LANGUAGE=JavaScript>
<!-- Begin
function login(){
var done=0;
var Senha=document.login.txtsenha.value;
Senha=txtsenha.toLowerCase();
var confsenha=document.login.txtconsenha.value;
confsenha=txtconsenha.toLowerCase();
if (Senha==confsenha) {
window.location="Cadastro.do"; done=1;
}
if (done==0) { alert("Dados incorretos, tente novamente"); }
}
//-->
</script>
</head>
<body>
Cadastro de Login <br><br>
<form name=login>
Login:<input type="text" name="txtlogin"> <br>
Senha:<input type= "password" name="txtsenha"> <br>
Confirmar Senha:<input type= "password" name="txtconsenha"><br>
<input type ="button" value = "Cadastrar" onClick=login()> <br>
</form>
</body>
</html>