-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdelstudent.php
More file actions
27 lines (25 loc) · 754 Bytes
/
delstudent.php
File metadata and controls
27 lines (25 loc) · 754 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php
session_start();
if(isset($_SESSION['adminid']) && isset($_SESSION['adminpswd']))
{
$user=$_SESSION['adminid'];
$pass=$_SESSION['adminpswd'];
}
else
{
echo '<script>alert("plzz login")</script>';
echo '<META http-equiv="refresh" content="0;logout.php">';
}
$id=$_GET['id'];
$sql="delete from studentdetails where id='$id'";
include 'dbconfigg.php';
if(mysqli_query($conn,$sql))
{
echo '<script>alert("student record Deleted Successful")</script>';
echo '<meta http-equiv="refresh" content="0;viewstudent.php"/>';
}
else
{
echo "deleted unsuccessfull";
}
?>