-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathview.php
More file actions
129 lines (61 loc) · 1.18 KB
/
Copy pathview.php
File metadata and controls
129 lines (61 loc) · 1.18 KB
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?php
include "header.php";
?>
<form>
<table width="80%" border=1>
<tr>
<td width="80%">
<b>Quiz(s)</b>
</td>
<td>
<b>on</b>
</td>
<td>
<b>Delete</b>
</td>
</tr>
<?php
if(isset($_REQUEST['id']))
{
$r = mysql_query('select * from mcq_practice where mcqn_id='.$_REQUEST['id']);
while($row = mysql_fetch_assoc($r))
{
echo '<tr>
<td>
'.$row['question'].'
</td>
<td>
'.$row['datetime'].'
</td>
<td>
<a href=view.php?did='.$row['mcqp_id'].'&id='.$_REQUEST['id'].' onclick="Return deleletconfig()" >Delete</a>
</td>
</tr>
';
}
}
if(isset($_REQUEST['did']))
{
$r = mysql_query('delete from mcq_practice where mcqp_id='.$_REQUEST['did']);
if($r)
{
//echo "<script>alert('1 Record Deleted...');</script>";
header('location:view.php?id='.$_REQUEST['id']);
}
}
?>
<script type="text/javascript">
function deleletconfig()
{
var result = confirm("Do you Really want to Delete?");
if (result==true){
alert ("Record deleted...")
}
return result;
}
</script>
</table>
</form>
<?php
include "footer.php";
?>