-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcreateAccount.php
More file actions
109 lines (98 loc) · 4.61 KB
/
createAccount.php
File metadata and controls
109 lines (98 loc) · 4.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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
#!/usr/local/bin/php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<!--<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />-->
<!-- Material Design fonts -->
<link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family=Roboto:300,400,500,700">
<link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/icon?family=Material+Icons">
<!-- Bootstrap -->
<link rel="stylesheet" type="text/css" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<!-- Bootstrap Material Design -->
<link rel="stylesheet" type="text/css" href="css/bootstrap-material-design.css">
<link rel="stylesheet" type="text/css" href="css/ripples.min.css">
<title>CellCheck - Register</title>
<style type="text/css">
* { margin: 0; padding: 0; }
p { margin-top: 5%;padding: 0px; }
.left { position: absolute; left: 0; top: 0; width: 70%; height: 100%; background-image:url("images/index.jpg"); background-size:100% 100%; vertical-align: middle;}
.left-inner{width: 70%; margin: 0 auto;}
.center{position:absolute; top:33%; width: 70%}
.right { position: absolute; right: 0; top: 0; width: 30%; height: 100%; background: #49B24E}
.center2{position:absolute; top:15%; width: 70%}
</style>
</head>
<body>
<div class = "left">
<div class = "left-inner">
<div class = "center">
<h1 style="color:white">Register now</h1>
<h3 style="color:#d3d3d3">A single account with many benefits</h3>
<p style="color:#d3d3d3" ;=""><b>Why register for CellCheck.com?</b>
<ul style="color:#d3d3d3">
<li>It is completely free!</li>
<li>Constant access to accurate and concise information about cell towers and their signal strength in respects to cell phone carriers.</li>
<li>Idetifiy the best service for your given location. </li>
<li>Unbiased representation of data to help you decide which cell phone carrier to invest in. </li>
</ul></p><br>
<a href="index.html" class="btn btn-raised btn-success">I already have an account</a>
</div>
</div>
</div>
<div class = "right">
<div class = "left-inner">
<div class = "center2">
<h3 style="color: white">Account Info</h3>
<form action="createAccount.php" method="post">
<div class="form-group label-floating">
<label class="control-label" for="username">Email</label>
<input class="form-control" name="username" type="text">
</div>
<div class="form-group label-floating">
<label class="control-label" for="password">Password</label>
<input class="form-control" name="password" type="password">
</div>
<h3 style="color: white">Personal Info</h3>
<div class="form-group label-floating">
<label class="control-label" for="fname">First Name</label>
<input class="form-control" name="fname" type="text">
</div>
<div class="form-group label-floating">
<label class="control-label" for="lname">Last Name</label>
<input class="form-control" name="lname" type="text">
</div>
<div class="form-group label-floating">
<label class="control-label" for="address">Address</label>
<input class="form-control" name="address" type="text">
</div>
<div class="checkbox">
<label>
<input type="checkbox"> By clicking register you agree to the terms and condition.
</label>
</div>
<input type="submit" class="btn btn-raised btn-default">
</form>
<?php
$connection = oci_connect($username = 'anrivera', $password = '$MarkusS4301!', $connection_string = '//oracle.cise.ufl.edu/orcl');
if (!$connection) {
$m = oci_error();
echo $m['message'], "\n";
exit;
}
else {
//print "Sucessfully connected to Oracle!\n";
}
$newname = "$_POST[fname] $_POST[lname]";
$sqlstatement = "INSERT INTO Customer (email, Address, Name, Password) values('$_POST[username]', '$_POST[address]', '$newname', '$_POST[password]')";
$test = oci_parse($connection, $sqlstatement);
oci_execute($test);
//Add user already exists if statements
oci_free_statement($test);
oci_close($connection);
echo "Thanks, $_POST[fname], your account was created.";
?>
</div>
</div>
</div?
</body>
</html>