-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdelet_marquee.php
86 lines (76 loc) · 2.05 KB
/
delet_marquee.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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<html>
<head>
<style>
.news{
width:96%;
border-radius: 8px;
border-color: black;
background-color: white;
float: right;
margin-right: 2%;
margin-top: 3%;
}
.centerdiv{
width: 65%;
height: 40%;
border: 1px solid;
border-color: black;
float: right;
}
</style>
<link href="css/style.css" type="text/css" rel="stylesheet" />
</head>
<body class="body">
<?php
include('databasedadi.php');
//include('headerdadi.php');
//echo '<div class="zaminehabi">';
//include('rightmenu.php')
?>
<form name="nform" method="post">
<?php
$error='';
if($_SERVER['REQUEST_METHOD']=="POST"){
$id= $_GET['id'];
$a=$_POST['yourmarquee'];
if($a==null){
$error="لطفا فیلد را پر نمایید";
}
else{
$e=$_POST['yourmarquee'];
}
$query = "delete from marquee where id=".$id."";
$result2 = rundelete($query);
header("location:manage.php");
}
?>
<table border="2">
<?php
$marquee2='';
$id= $_GET['id'];
$sql1= " select * from marquee where id =".$id."";
$result1 = runSelect($sql1);
while ($row =$result1->fetch(PDO::FETCH_ASSOC)) {
$mp=$row['id'];
$marquee2=$row['textmarquee'];
}
?>
<tr>
<td>
<textarea name="yourmarquee" rows="20" cols="70"><?php echo $marquee2; ?> </textarea>
</td>
</tr>
<tr>
<td></td>
<td></td>
<td>
<input type="submit" value="حذف">
</td>
</tr>
<tr>
<td><?php echo $error;?></td>
</tr>
</table>
</form>
</body>
</html>