-
Notifications
You must be signed in to change notification settings - Fork 0
/
admin3.cfm
70 lines (65 loc) · 2.55 KB
/
admin3.cfm
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
<cfinclude template="translatit.cfm">
<cfquery name="getpass" datasource="#attributes.dsn#">
SELECT *
FROM login
WHERE username='#user#'
</cfquery>
<cfif (#pass# is #getpass.password#) AND (#user# is #getpass.username#)>
<cfif (#getpass.adminlevel# is 2)>
<center>
<cfform action="loginpost.cfm" method="post">
<cfinput type="Hidden" name="pass" value="#getpass.password#">
<cfinput type="Hidden" name="user" value="#getpass.username#">
<cfinput type="submit" value="Back to Admin Page" name="b1">
</cfform>
<!------------ insert page here ----------->
<br><br><br><br>
<center>
<cfform action="admin3a.cfm" method="post" name="addlogin">
Username<cfinput name="username" required="yes" message="You must enter a username" size="50"><br>
Password<cfinput name="password" required="yes" message="You must enter a password" size="50"><br>
Level<cfselect size="1" name="adminlevel" style="width: 150px" >
<option>1</option>
<option>2</option>
</cfselect>
District <cfselect size="1" name="district" style="width: 150px">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
<option>6</option>
<option>7</option>
<option>8</option>
<option>9</option>
<option>10</option>
<option>11</option>
<option>12</option>
<option>13</option>
<option>14</option>
<option>15</option>
<option>16</option>
<option>17</option>
</cfselect><br>
<cfinput type="Hidden" name="pass" value="#getpass.password#">
<cfinput type="Hidden" name="user" value="#getpass.username#">
<cfinput type="submit" value="Upload New Administrator" name="b3">
</cfform>
<!------------ ende page insert ----------->
</center>
<br><br><br>
<cfelse>
You are not authorized to access this function<br />
<cfform action="loginpost.cfm" method="post">
<cfinput type="Hidden" name="pass" value="#getpass.password#">
<cfinput type="Hidden" name="user" value="#getpass.username#">
<cfinput type="hidden" name="level" value="#getpass.adminlevel#">
<cfinput type="submit" value="Back to Admin Page" name="b1">
</cfform>
</cfif>
<cfelse>
<font face="Arial" size="4">Sorry, you must enter a correct username and password!<br>
<br>
<a href="login.cfm">Back to Login</a></font></center>
<!-- Here you are ending your statement for username and password -->
</cfif>