﻿var txtEmail = "";
var txtPW = "";

window.onload = function(){
    txtEmail = document.getElementById("txtEmail");
    txtPW = document.getElementById("txtPW");
    
    if( txtEmail.value == "" ){ txtEmail.focus(); return; }
    if(txtPW.value == "" ){ txtPW.focus(); return; }
    
}

function OnSubmit(){
    
    if ( chkInput(txtEmail) == false ) return false;
    if ( chkInput(txtPW) == false ) return false;
    return true
}

function chkInput(e){
    if ( e.value == "" ){
        e.style.borderColor = "#f00";
        e.focus();
        return false
    }
}


function cmdVergessen_OnClick(){
    if ( chkInput(txtEmail) == false ) return false;
    window.location.href="default.aspx?pw=" + txtEmail.value;
}



