-
Notifications
You must be signed in to change notification settings - Fork 2
/
delete.php
45 lines (40 loc) · 1.35 KB
/
delete.php
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?php
require("header.php");
if(CheckPermission("Delete".$_GET['s']) OR $_GET['s'] == 'ClubManager' OR $_GET['s']== 'ManageUsers')
{
if(isset($_POST['delete']))
{
$table = $_GET['t'];
$id = $_GET['i'];
MySQL::NonQuery("DELETE FROM $table WHERE id = ?",'@s',$id);
echo '
<script>
window.history.go(-2);
</script>
';
die();
}
if(isset($_POST['abort']))
{
echo '
<script>
window.history.go(-2);
</script>
';
}
echo '
<form action="'.ThisPage().'" method="post" accept-charset="utf-8" enctype="multipart/form-data">
<center>
<br>
<h1 class="stagfade1">Eintrag wirklich löschen?</h1>
<br>
<h2 class="stagfade2" style="color: #000000">Nach dem Löschen kann der Eintrag nicht wiederhergestellt werden!</h2>
<br><br>
<button type="submit" name="delete" class="cef_warning">Löschen</button>
<button type="submit" name="abort">Abbrechen</button>
</center>
</form>
';
}
include("footer.php");
?>