-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathactivate.php
More file actions
executable file
·62 lines (62 loc) · 1.6 KB
/
Copy pathactivate.php
File metadata and controls
executable file
·62 lines (62 loc) · 1.6 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
<?php include("includes/connection.php"); ?>
<!DOCTYPE HTML
<html lang="en-US">
<head>
<title>Account Activation</title>
<link rel="stylesheet" type="text/css" href="css.css" />
</head>
<body>
<div id="wrapper">
<?php include("header.php"); ?>
<div id="main_section">
<?php
$db = mysql_select_db("realrandomradio", $connect);
$result = mysql_query("SELECT * FROM temp_dj
WHERE '$_GET[id]' = password");
while($row = mysql_fetch_array($result))
{
$fname = $row['first_name'];
$lname = $row['last_name'];
$email = $row['email'];
$djname = $row['dj_name'];
$password = $row['password'];
if(mysql_num_fields($result) == 0)
{
echo "You are currently not registered.<br>
You need to provide some basic information before you can access this page!<br>
<a href='http://www.realrandomradio.com/register.php'>Click here</a> to register.";
}
else if(mysql_num_fields($result) == 1)
{
$result2 = mysql_query("INSERT INTO perm_dj
(first_name, last_name, email, dj_name, password)
VALUES ('$fname', '$lname', '$email', '$djname', '$password')");
if(mysql_num_fields($result2) == 0)
{
$delete = mysql_query("DELETE FROM temp_dj
WHERE $password = password");
echo "Congratulations!<br>
You finally registered to become a RealRandomRadio DJ!";
}
else
{
echo "You are already registered with this ID.";
}
}
else
{
$result3 = mysql_query("SELECT * FROM perm_dj
WHERE '$_GET[id]' = password");
if(mysql_num_fields($result3) > 0)
{
echo "There was an error.<br>
Please contact the webmaster at edgar@realrandomradio.com.";
}
}
}
?>
</div>
<?php include("footer.php"); ?>
</div>
</body>
</html>