-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathupdateattribute.php
More file actions
executable file
·63 lines (60 loc) · 1.61 KB
/
Copy pathupdateattribute.php
File metadata and controls
executable file
·63 lines (60 loc) · 1.61 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
<?php
session_start();
if (!isset($_SESSION['user']))
{
header("Location: login.php");
}
?>
<html>
<head><title>Attribute Update</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link href= "css/adminsettingsstyle.css" rel="stylesheet" type="text/css">
<script src="js/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="js/jquery.validate.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$("#commentForm").validate();
});
</script>
</head>
<body>
<div id="stylized" class="myform">
<h3>Attribute Update</h3>
Please fill the value
<?php
require "config.php";
//User Permissions
$access=mysql_result($permission, 42);
if($access != "1")
{
echo "<p>Not permitted</p>";
exit;
}
$attid=$_GET['attid'];
//this code is bringing in the values for the dropdown task types
$sql1="SELECT descr FROM attributes WHERE id = $attid";
/* You can add order by clause to the sql statement if the names are to be displayed in alphabetical order */
$result = mysql_query ($sql1);
$row=mysql_fetch_array($result);
$formVars = array();
mysql_close();
?>
<FORM ACTION="updatemod2.php" METHOD="POST" NAME="updateattribute_form" id="commentForm">
<table>
<tr>
<td>
<input type="text" name="attdescr" value="<?php echo $row[descr]; ?>" class="required" size="60">
</td>
<input type=hidden name=attid value="<?php echo $attid; ?>">
</tr>
</table>
<TABLE>
<TR>
<TH><input type="submit" value="Submit" name="Submit" class="button"></TH>
</FORM>
<th><INPUT TYPE="button" VALUE="Close" onClick="self.close()" class="button"></th>
</TR>
</TABLE>
<!-------------end form------------>
</body>
</html>