            <!-- TOP Nav Bar END -->
            <div class="container-fluid">
               <div class="row">
                 <div class="col-sm-2 col-lg-2"></div>
                  <div class="col-sm-8 col-lg-8">
                     <div class="iq-card">
                        <div class="iq-card-header d-flex justify-content-between">
                           <div class="iq-header-title">
                              <h4 class="card-title">Edit Password</h4>
                           </div>
                        </div>
                        <div class="iq-card-body">
                           <div class="alert alert-success PassUpdMsg" style="display: none;">
                                <strong>Password Successfully Updated!</strong>
                            </div>
                            <div class="alert alert-danger PassFailedMsg" style="display: none;">
                                <strong>Please Enter Correct Old Password!</strong>
                            </div>
                           <form role="form" method="post" id="addfrm">
                              <div class="row"> 
                              <div class="col-sm-12 col-lg-12">  
                                 <div class="form-group">
                                    <label for="InputText1">Old Password </label>
                                    <input type="password" class="form-control" name="old_password" id="old_password" placeholder="Old Password" required>
                                 </div>
                              </div>
 
                              <div class="col-sm-12 col-lg-12">  
                                 <div class="form-group">
                                    <label for="InputText1">New Password </label>
                                    <input type="password" class="form-control" name="new_pass" id="new_pass" placeholder="New Password" required>
                                 </div>
                              </div>
 
                              <div class="col-sm-12 col-lg-12">  
                                 <div class="form-group">
                                    <label for="InputText1">Confirm New Password </label>
                                    <input type="password" class="form-control" name="con_new_pass" id="con_new_pass" placeholder="Confirm New Password" required>
                                 </div>
                              </div>

                              <div class="col-sm-12 col-lg-12">
                              <button type="submit" class="btn btn-primary addbtn">Submit</button>
                              <button class="btn btn-primary addload buttonload" style="display: none;"><i class="fa fa-spinner fa-spin" style=" margin-left: -12px; margin-right: 8px;"></i>Please Wait</button>
                              <button type="submit" class="btn iq-bg-danger">cancel</button>
                           </div>

                              </div>
                           </form>
                        </div>
                     </div>
                  </div>
               </div>
            </div>
            
           
<script>
// just for the demos, avoids form submit
jQuery.validator.setDefaults({
success: "valid"
});
$("#addfrm").validate({
rules: {
    old_password: {
         required: true
       },
       new_pass : {
            minlength : 5
        },
        con_new_pass : {
            minlength : 5,
            equalTo : "#new_pass"
        }
}
});
</script>
<script>
$(document).ready(function(e) {
$("#addfrm").on('submit', function(e) {
e.preventDefault();
var formStatus = $('#addfrm').validate().form();
if (true == formStatus) {
$.ajax({
type: 'POST',
url: '<?php echo base_url(); ?>profile/change_pass',
data: new FormData(this),
contentType: false,
cache: false,
processData: false,
beforeSend: function() {
$('.addbtn').hide();
$('.addload').show();
},
success: function(msg) {
if(msg=='success')
{
$(".PassUpdMsg").show();
$('.PassUpdMsg').delay(3000).hide(200);
$('.addbtn').show();
$('.addload').hide();
setInterval(function() {
location.reload();
}, 3000);
}
else
{
$(".PassFailedMsg").show();
$('.PassFailedMsg').delay(3000).hide(200);
$('.addbtn').show();
$('.addload').hide();

}
}
});
}
});
});
</script>