📁 File Manager
Editing:
/home/wvl7mof7402e/public_html/carkp.in/admin/display.php
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <link rel="stylesheet" href="css/style.css"> <link rel="stylesheet" href="css/bootstrap.css"> <title>Document</title> </head> <body> <?php require "navbar.php"; require "dbconnect.php"; if(isset($_GET['type']) && $_GET['type']!=''){ $type = $_GET['type']; if($type=='delete'){ $id = $_GET['id']; $delete_sql = "delete from user_register where id='$id'"; mysqli_query($con,$delete_sql); } } ?> <div class="container-fluid my-3"> <table class="table table-bordered"> <thead> <tr> <th>Image</th> <th></th> </tr> </thead> <tbody> <?php $sql = "select * from user_register order by id desc"; $result = mysqli_query($con,$sql); while($row1=mysqli_fetch_assoc($result)){ ?> <tr> <td><img src="upload/<?php echo $row1['image']?>" height="60"></td> <td class="text-right"> <?php echo "<a class='btn btn-danger' href='?type=delete&id=".$row1['id']."'>Delete</a>"; ?> </td> </tr> <?php } ?> </tbody> </table> </div> </body> </html>
Save
Cancel