forked from Rizwan17/messenger
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
87 lines (74 loc) · 2.4 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
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
<?php
session_start();
if (isset($_SESSION['user_uuid'])) {
header("location:chat.php");
}
?>
<!DOCTYPE html>
<html>
<head>
<title></title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<!-- Firebase App is always required and must be first -->
<script src="https://www.gstatic.com/firebasejs/5.7.0/firebase-app.js"></script>
<!-- Add additional services that you want to use -->
<script src="https://www.gstatic.com/firebasejs/5.7.0/firebase-auth.js"></script>
<script src="https://www.gstatic.com/firebasejs/5.7.0/firebase-firestore.js"></script>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<div class="main-wrapper">
<header class="header">
<div class="logo">
<a href="#">My Messenger</a>
</div>
<div class="menu">
<a href="#" class="login-register-btn">
<span class="active">Register <i class="fas fa-user"></i></span>
<span class="">Login <i class="fas fa-user"></i></span>
</a>
</div>
</header>
<div class="card">
<div class="content active">
<h2>Login</h2>
<form id="login-form" onsubmit="return false">
<div class="form-input" >
<input type="text" name="username" placeholder="Username" autocomplete="off">
</div>
<div class="form-input">
<input type="password" name="password" placeholder="Password" autocomplete="off">
</div>
<input type="hidden" name="login_user" value="1">
<div class="form-input">
<button id="login-btn">Login</button>
</div>
</form>
</div>
<div class="content">
<h2>Register</h2>
<form id="register-form" onsubmit="return false">
<div class="form-input">
<input type="text" name="fullname" placeholder="Full Name">
</div>
<div class="form-input">
<input type="text" name="username" placeholder="Username">
</div>
<div class="form-input">
<input type="email" name="email" placeholder="Email">
</div>
<div class="form-input">
<input type="password" name="password" placeholder="Password">
</div>
<input type="hidden" name="register_user" value="1">
<div class="form-input">
<button id="register-btn">Register</button>
</div>
</form>
</div>
</div>
</div>
<script type="text/javascript" src="js/firestore-config.js"></script>
<script type="text/javascript" src="js/main.js"></script>
</body>
</html>