0xV3NOMx
Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64



Your IP : 3.23.102.79


Current Path : /var/www/html/univadmin/rrit/js/
Upload File :
Current File : /var/www/html/univadmin/rrit/js/forgotpwd.js

function sendOtpForgot(){
 var fmob = $("#fmob").val();

 $.ajax({
     type:"POST",
     url:"php/sendotpfrgt.php",
     data:"fmob="+fmob,
     success: function (res) {
         var status = JSON.parse(res);
        if(status.msg == "success"){
            Swal.fire({
                title: "OTP Sent to your mobile.",
                type: "success",
                confirmButtonColor: "#00FF00",
                confirmButtonText: "OK",
                closeOnConfirm: false
            });
        }else if(status.msg == "error"){
            Swal.fire({
                title: "Something Went Wrong",
                type: "Error",
                showCancelButton: false,
                confirmButtonColor: "#FFFF00",
                confirmButtonText: "OK",
                closeOnConfirm: false
            });
        }else {
            Swal.fire({
                title: "Invalid",
                type: "Invalid",
                showCancelButton: false,
                confirmButtonColor: "#FF0000",
                confirmButtonText: "OK",
                closeOnConfirm: false
            });
        }
     }
 })
}

function resetPassword(){
    var fmob = $("#fmob").val();
    var fpwd = $("#fpwd").val();
    var rfpwd = $("#re_pass").val();
    var fotp = $("#fotp").val();

    if(fpwd == rfpwd){
        $.ajax({
            type: "POST",
            url: "php/frgtpwd.php",
            data: "fmob="+fmob+"&fpwd="+fpwd+"&fotp="+fotp,
            success: function (res){
                var status = JSON.parse(res);
                if(status.status == "success"){
                    Swal.fire({
                        title: "Password Reset Success",
                        type: "success",
                        confirmButtonColor: "#00FF00",
                        confirmButtonText: "OK",
                        closeOnConfirm: false
                    });
                }else if(status.status == "error"){
                    Swal.fire({
                        title: "Something Went Wrong",
                        type: "Error",
                        showCancelButton: false,
                        confirmButtonColor: "#FFFF00",
                        confirmButtonText: "OK",
                        closeOnConfirm: false
                    });
                }else{
                    Swal.fire({
                        title: "Invalid",
                        type: "Invalid",
                        showCancelButton: false,
                        confirmButtonColor: "#FF0000",
                        confirmButtonText: "OK",
                        closeOnConfirm: false
                    });
                }
            }
        })
    }else{
        Swal.fire({
            title: "Invalid",
            type: "Invalid",
            showCancelButton: false,
            confirmButtonColor: "#FF0000",
            confirmButtonText: "OK",
            closeOnConfirm: false
        });
    }
}