EVOLUTION-NINJA
Edit File: forgot_password.php
<!DOCTYPE HTML> <html lang="en-US"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta http-equiv="X-UA-Compatible" content="IE=Edge" /> <title>Home</title> <link rel="stylesheet" type="text/css" href="<?php echo base_url('assets/css/main.css'); ?>"/> <link rel="stylesheet" type="text/css" href="<?php echo base_url('assets/css/bootstrap.min.css'); ?>" /> <link rel="stylesheet" type="text/css" href="<?php echo base_url('assets/css/font-awesome.min.css'); ?>" /> <link rel='shortcut icon' type='image/x-icon' href='<?php echo base_url('assets/images/fav_icon.png'); ?>' /> <link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet"> <script type="text/javascript" src="<?php echo base_url('assets/js/jquery-2.2.4.min.js')?>"></script> <script type="text/javascript" src="<?php echo base_url('assets/js/bootstrap.min.js')?>"></script> <!-- Include toastr JavaScript --> <script src="https://cdnjs.cloudflare.com/ajax/libs/toastr.js/latest/toastr.min.js"></script> <!-- Include toastr CSS --> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/toastr.js/latest/toastr.min.css"> </head> <body> <section class="top_head"> <div class="container-fluid"> <img src="<?php echo base_url('assets/images/login_logo.png');?>" class="img-responsive" /> </div><!--container end--> </section> <!--top end--> <section class="top_img_mid"> <h2 class="text-center">WELCOME</h2> <p class="text-center">Please login to access your Account</p> </section> <section class="signin_mid"> <div class="container-fluid"> <div class="col-sm-3 col-md-4"></div> <div class="col-sm-6 col-md-4 tile"> <div class="tile-header"> <h2 class="text-center">Forgot Password</h2> </div> <div class="tile-body"> <form id="forgot_password"> <label class="form-input"> <input type="text" autofocus="true" name="username" required/> <span class="label">Username</span> <span class="underline"></span> </label> <label class="form-input"> <input type="text" name="email" required/> <span class="label">Email</span> <div class="underline"></div> </label> <button class="btn h_btn" type="submit">Submit</button> </form> </div> </div> </div> </section> <script type="text/javascript"> $('#forgot_password').submit(function(e){ e.preventDefault(); formdata = new FormData($(this)[0]); $.ajax({ type : 'post', url : '<?php echo site_url("/change-forgot-password")?>', data : formdata, contentType: false, processData: false, success:function(response){ response=jQuery.parseJSON(response); if(response.result == 1) { toastr["success"](response.message); } else { toastr["error"](response.message); } } }); }); </script> </body> </html>