GIF89a
<?php ob_start(); ini_set('error_reporting', E_STRICT); include("session.php"); include("connect.php"); include("libs.php"); mysqli_set_charset($conn,'utf8'); date_default_timezone_set('Asia/Kolkata'); //setOnline($conn,$_COOKIE["user_id"]); ?> <!DOCTYPE html> <html> <?php include'head.php'; ?> <body> <section style="margin-bottom: 100px;"> <div class="container my-2"> <div class="row d-flex justify-content-center"> <div class="col-xs-5 col-sm-8 col-md-8 col-lg-6 col-xl-4"> <?php $sqlP="SELECT * FROM `app_admin` WHERE `sr`='".$_COOKIE["user_id"]."'"; $rsP=mysqli_query($conn,$sqlP); $rowP=mysqli_fetch_assoc($rsP); ?> <div class="card border-0" id="chat1"> <div class="card border-0 d-flex justify-content-between align-items-center p-3"> <div class="card border-0" style="width: 18rem;"> <div class="bg-dark rounded"> <img src="<?php echo findDP($conn,$rowP["image"]); ?>" class="d-flex m-auto" style="height:auto; max-width: 50%"> </div> <div class="card-body"> <h6 class="card-title">Name : <?php echo $rowP["user_name"]; ?></h6> <h6 class="card-title">Age : <?php echo $rowP["age"]; ?></h6> </div> </div> </div> <h4 class="d-flex mx-auto my-4">Edit Your Profile</h4> <form class="mx-4 mx-md-4 my-1" method="POST" action="updatePic.php" enctype="multipart/form-data" onsubmit="return validPic(this)"> <div class="d-flex flex-row align-items-center mb-4"> <div class="form-outline flex-fill mb-0"> <input type="text" id="uname" name="name" value="<?php echo $rowP["user_name"]; ?>" class="form-control" placeholder="Your Name" /> </div> </div> <div class="d-flex flex-row align-items-center mb-4"> <div class="form-outline flex-fill mb-0"> <input type="number" id="mobb" name="mobile" value="<?php echo $rowP["mobb"]; ?>" class="form-control" placeholder="Mobile Number" /> </div> </div> <div class="d-flex flex-row align-items-center mb-4"> <div class="form-outline flex-fill mb-0"> <select id="gender" class="form-control"> <?php $sqlG="SELECT * FROM `gender`"; $rsG=mysqli_query($conn,$sqlG); while($rowG=mysqli_fetch_array($rsG)){ if($rowP["gender"]==$rowG['type']){ ?> <option selected="selected" value="<?php echo $rowG['type']; ?>"><?php echo $rowG['type']; ?></option> <?php } else { ?> <option value="<?php echo $rowG['type']; ?>"><?php echo $rowG['type']; ?></option> <?php } } ?> </select> </div> </div> <div class="d-flex flex-row align-items-center mb-4"> <div class="form-outline flex-fill mb-0"> <input type="text" id="password" name="password" value="<?php echo $rowP["password"]; ?>" class="form-control" placeholder="New Password" /> </div> </div> <div class="d-flex flex-row align-items-center mb-4"> <div class="form-outline flex-fill mb-0"> <input type="number" id="age" name="password" value="<?php echo $rowP["age"]; ?>" class="form-control" placeholder="Confirm New Password" /> </div> </div> <div class="d-flex justify-content-center mx-4 mb-3 mb-lg-4"> <button type="button" class="btn btn-dark btn-lg fs-5 px-5" onclick="updateProfile('<?php echo $_COOKIE["user_id"]; ?>')">Update</button> </div> <div class="d-flex justify-content-center mx-4 mb-3 mb-lg-4"> <input name="image" id="image" type="file" class="btn btn-danger d-flex m-auto my-3"></input> <input name="srr" type="hidden" value="<?php echo $rowP["sr"]; ?>"> </div> <div class="d-flex justify-content-center mx-4 mb-3 mb-lg-4"> <button type="submit" class="btn btn-dark btn-lg fs-5 px-5" >Update Photo</button> </div> </form> </div> </div> </div> </div> </section> <?php include 'footer.php'; ?> </body> </html> <div id="snackbar"><span id="snack_msgg" style="color: white"></span></div>