User edit section in college notes management project

 User can edit the details : 


<?php
      include 'conn.php';
    ?>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Bookstore</title>
    <link rel="stylesheet" href="css/bootstrap.min.css">
</head>
<body>
<div class="container">
            <h2>Student Details</h2>
           
            <table class="table table-bordered">
              <thead>
                <tr>
                  <th>ID</th>
                  <th>NAME</th>
                  <th>EMAIL</th>
                  <th>MOBILE NO</th>
                 
                </tr>
                <?php
    $id = $_GET['id'];
    $sql = "SELECT *FROM users WHERE id = '$id' ";
    $result = mysqli_query($conn ,$sql);
    if(mysqli_num_rows($result)>0) {
        while ($user = mysqli_fetch_assoc($result)){ ?>
   
              </thead>
              <tbody>
                <tr>
               <td><?php echo $user['id']; ?> </td>
               <td><?php echo $user['uname'] ;?> </td>
               <td><?php echo $user['uemail']; ?> </td>
               <td><?php echo $user['uno'] ;?> </td>
                 
                </tr>
               
               
               

   
              </tbody>
              <?php   }

} else{
    echo '0 result';
}
?>
            </table>
           
           
                 
          </div>

    <script src="js/jquery.min.js"></script>
    <script src="js/bootstrap.min.js"></script>
</body>
</html>

Post a Comment

0 Comments

Close Menu