-
Notifications
You must be signed in to change notification settings - Fork 8
/
signup.php
198 lines (179 loc) · 8.91 KB
/
signup.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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
<!DOCTYPE html>
<html >
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="generator" content="Mobirise v5.2.0, mobirise.com">
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1">
<link rel="shortcut icon" href="assets/images/feminine-128x128.png" type="image/x-icon">
<meta name="description" content="">
<title>Signup</title>
<link rel="stylesheet" href="styles/login.css">
<link rel="stylesheet" href="assets/web/assets/mobirise-icons2/mobirise2.css">
<link rel="stylesheet" href="assets/tether/tether.min.css">
<link rel="stylesheet" href="assets/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" href="assets/bootstrap/css/bootstrap-grid.min.css">
<link rel="stylesheet" href="assets/bootstrap/css/bootstrap-reboot.min.css">
<link rel="stylesheet" href="assets/dropdown/css/style.css">
<link rel="stylesheet" href="assets/socicon/css/styles.css">
<link rel="stylesheet" href="assets/theme/css/style.css">
<link rel="preload" as="style" href="assets/mobirise/css/mbr-additional.css">
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Dancing+Script:wght@700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="assets/mobirise/css/mbr-additional.css" type="text/css">
</head>
<?php
session_start();
if(isset($_POST['doctor'])){
require_once('./config.php');
$email=$_POST['email'];
$u_name= $_POST['u_name'];
$pass= $_POST['pass'];
$uid= uniqid($u_name);
$occupation= "doctor";
$securepass= crypt($pass,$u_name);
$sql= "INSERT INTO `feminine`.`users` (`userid`, `username`, `password`, `email`, `occupation`) VALUES ('$uid', '$u_name', '$securepass', '$email', '$occupation');";
if($con->query($sql) == true){
echo "<br><br><br><h3 style='margin-left:400px;margin-top:20px;color:green' >You have successfully registered<a href='login.php'>Go back to Login Page</a></h3>";
}
else{
echo "ERROR: $con->error";
}
$con->close();
}
if(isset($_POST['patient'])){
require_once('./config.php');
$email=$_POST['email'];
$u_name= $_POST['u_name'];
$pass= $_POST['pass'];
$uid= uniqid($u_name);
$occupation= "patient";
$securepass= crypt($pass,$u_name);
$sql= "INSERT INTO `feminine`.`users` (`userid`, `username`, `password`, `email`, `occupation`) VALUES ('$uid', '$u_name', '$securepass', '$email', '$occupation');";
if($con->query($sql) == true){
echo "<br><br><br><h3 style='margin-left:400px;margin-top:20px;color:green' >You have successfully registered<a href='login.php'>Go back to Login Page</a></h3>";
}
else{
echo "ERROR: $con->error";
}
$con->close();
}
?>
<body>
<section class="menu cid-s48OLK6784" once="menu" id="menu1-h">
<nav class="navbar navbar-dropdown navbar-fixed-top navbar-expand-lg">
<div class="container-fluid">
<div class="navbar-brand">
<span class="navbar-logo">
<a href="index.php">
<img src="assets/images/feminine-1-335x335.png" alt="login" style="height: 5rem;">
</a>
</span>
</div>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarNavAltMarkup" aria-expanded="false" aria-label="Toggle navigation">
<div class="hamburger">
<span></span>
<span></span>
<span></span>
<span></span>
</div>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav nav-dropdown" data-app-modern-menu="true">
<li class="nav-item">
<a class="nav-link link text-black display-4" href="index.php#features1-n">Features</a>
</li>
<li class="nav-item">
<a class="nav-link link text-black display-4" href="index.php#tabs1-p">AI Tools</a>
</li>
<li class="nav-item">
<a class="nav-link link text-black display-4" href="signup.php">Dashboard</a>
</li>
<li class="nav-item dropdown">
<a class="nav-link link text-black dropdown-toggle display-4" href="#" data-toggle="dropdown-submenu" aria-expanded="false">Book</a>
<div class="dropdown-menu">
<a class="text-black dropdown-item display-4" href="labs.html">Lab Appointment</a>
<a class="text-black dropdown-item display-4" href="consult-doc.html">Expert Consultancy</a>
</div>
</li>
<li class="nav-item">
<a class="nav-link link text-black display-4" href="Tracker.php">Period Tracker</a>
</li>
</ul>
</div>
</div>
</nav>
</section>
<section class="image1 login-section" id="image1-m" style="padding:0px 10%;">
<div class="container login">
<div class="col-12 col-lg-6">
<img src="assets/images/login.jpg" alt="log-in">
</div>
<div class="col-12 col-lg-6" >
<div class="text-wrapper align-items-right" >
<h3 class="mbr-section-title mbr-fonts-style display-5">
<strong style="font-family: 'Dancing Script', cursive; ">Sign Up</strong>
</h3>
<div>
<form method="post" id="signupForm">
<div class="form-floating form-field-login">
<label for="name">Userame</label>
<input type="name" class="form-control" id="u_name" placeholder="Name" name="u_name">
</div>
<div class="form-floating form-field-login">
<label for="email">Email Address</label>
<input type="email" class="form-control" id="email" placeholder="Email Address" name="email">
</div>
<div class="form-floating form-field-login">
<label for="password">Password</label>
<input type="password" class="form-control" id="password" placeholder="Password" name="password">
</div>
<button type="submit" class="btn btn-danger" name="patient" id="patient">Sign Up As Patient</button>
OR
<button type="submit" class="btn btn-danger" name="doctor" id="doctor">Sign Up As Doctor</button>
<div class="form-floating form-field-login" style="text-align:center; margin:15px;">
<a href="login.php">Already a member? Click here to Login.</a>
</div>
</form>
</div>
</div>
</div>
</div>
</section>
<section class="footer3 cid-s48P1Icc8J" once="footers" id="footer3-i"><div class="container">
<div class="media-container-row align-center mbr-white">
<div class="row social-row">
<div class="social-list align-right pb-2">
<div class="soc-item">
<a href="https://twitter.com/mobirise" target="_blank">
<span class="mbr-iconfont mbr-iconfont-social socicon-github socicon"></span>
</a>
</div>
</div>
</div>
<div class="row row-copirayt">
<p class="mbr-text mb-0 mbr-fonts-style mbr-white align-center display-7">Made by Team HackDivas </p>
</div>
</div>
</div>
</section>
<a href="https://mobirise.site/e" "></a>
<script src="assets/web/assets/jquery/jquery.min.js"></script>
<script src="assets/popper/popper.min.js"></script>
<script src="assets/tether/tether.min.js"></script>
<script src="assets/bootstrap/js/bootstrap.min.js"></script>
<script src="assets/smoothscroll/smooth-scroll.js"></script>
<script src="assets/parallax/jarallax.min.js"></script>
<script src="assets/mbr-tabs/mbr-tabs.js"></script>
<script src="assets/dropdown/js/nav-dropdown.js"></script>
<script src="assets/dropdown/js/navbar-dropdown.js"></script>
<script src="assets/touchswipe/jquery.touch-swipe.min.js"></script>
<script src="assets/theme/js/script.js"></script>
</body>
<!-- <script>
$("#signupForm").submit(function(e){
e.preventDefault();
console.log("aaya");
})
</script> -->
</html>