function js_login(){ $('#action').val('31'); $('#stage').val('2'); $("#gf_login").submit(); } function js_forget(){ window.location.replace("/golf/cgi-bin/gf_reset_pwd.cgi"); } $(function() { const togglePassword = document.querySelector("#togglePassword"); const password = document.querySelector("#password"); togglePassword.addEventListener("click", function () { // toggle the type attribute const type = password.getAttribute("type") === "password" ? "text" : "password"; password.setAttribute("type", type); // toggle the eye icon this.classList.toggle('fa-eye'); this.classList.toggle('fa-eye-slash'); }); }); function js_bio(){ window.WTN.Biometric.checkStatus({ callback:function(data){ /* data returns the object below */ { // alert("Data: " + data.isSuccess + " touch: " + data.hasTouchId + " secret: " + data.hasSecret); if (data.isSuccess) { if (data.hasTouchId) { if (data.hasSecret) { window.WTN.Biometric.show({ prompt:"Please authenticate to continue", callback:function(data){ { if (data.isSuccess) { $('#bio_key').val(data.secret); $('#action').val('11'); $('#stage').val('2'); $("#gf_login").submit(); } } } }); } else { alert('Please login to enable biometric') } } else { alert('Biometric not supported on this device') } } } } }); }