-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
59 lines (56 loc) · 2.15 KB
/
index.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
<?php
// Copyright Davain Pablo Edwards core8@gmx.net. Licensed https://creativecommons.org/licenses/by-nc-sa/4.0/deed.en
// Only start the session if one hasn't been started yet
if (session_status() == PHP_SESSION_NONE) {
session_start();
}
// Check if the session variable 'unique_id' is set, and redirect if true
if (isset($_SESSION['unique_id'])) {
header("location: users.php");
}
include_once "header.php";
?>
<body>
<div class="wrapper">
<section class="form signup">
<header>MySQL + PHP Realtime Chat</header>
<form action="php/confirm_password.php" method="POST" enctype="multipart/form-data" autocomplete="off">
<div class="error-text"></div>
<div class="name-details">
<div class="field input">
<label>First Name</label>
<input type="text" name="fname" placeholder="First name" required>
</div>
<div class="field input">
<label>Last Name</label>
<input type="text" name="lname" placeholder="Last name" required>
</div>
</div>
<div class="field input">
<label>Email Address</label>
<input type="text" name="email" placeholder="Enter your email" required>
</div>
<div class="field input">
<label>Password</label>
<input type="password" name="password" placeholder="Enter new password" required>
<i class="fas fa-eye"></i>
</div>
<div class="field input">
<label>Confirm Password</label>
<input type="password" name="confirm_password" placeholder="Confirm your password" required>
</div>
<div class="field image">
<label>Select Image</label>
<input type="file" name="image" accept="image/x-png,image/gif,image/jpeg,image/jpg" required>
</div>
<div class="field button">
<input type="submit" name="submit" value="Continue to Chat">
</div>
</form>
<div class="link">Already signed up? <a href="login.php">Login now</a></div>
</section>
</div>
<script src="javascript/pass-show-hide.js"></script>
<script src="javascript/signup.js"></script>
</body>
</html>