-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsignup.html
118 lines (90 loc) · 5.34 KB
/
signup.html
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
<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<meta name="format-detection" content="telephone=no" />
<meta name="msapplication-tap-highlight" content="no" />
<meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width" />
<!-- This is a wide open CSP declaration. To lock this down for production, see below. -->
<meta http-equiv="Content-Security-Policy" content="default-src * 'unsafe-inline'; style-src 'self' 'unsafe-inline'; media-src *" />
<!-- Good default declaration:
* gap: is required only on iOS (when using UIWebView) and is needed for JS->native communication
* https://ssl.gstatic.com is required only on Android and is needed for TalkBack to function properly
* Disables use of eval() and inline scripts in order to mitigate risk of XSS vulnerabilities. To change this:
* Enable inline JS: add 'unsafe-inline' to default-src
* Enable eval(): add 'unsafe-eval' to default-src
* Create your own at http://cspisawesome.com
-->
<!-- <meta http-equiv="Content-Security-Policy" content="default-src 'self' data: gap: 'unsafe-inline' https://ssl.gstatic.com; style-src 'self' 'unsafe-inline'; media-src *" /> -->
<link rel="stylesheet" type="text/css" href="css/main.css"/>
<link rel="stylesheet" type="text/css" href="css/signup.css"/>
<link rel="stylesheet" type="text/css" href="css/semantic.min.css"/>
<link rel="stylesheet" type="text/css" href="css/font-awesome.min.css"/>
<title>Hello World</title>
</head>
<body>
<div class="logo">
<div class="logo2">
<h3 style="text-align:center;">gothere</h3>
</div>
</div>
<div class="ui form">
<form method="post">
<div class="form2">
<input type="text" placeholder="Full name" id="name" size="45"><br/><br/>
<input type="text" placeholder="Username" id="username" size="45"><br/><br/>
<input type="email" placeholder="E-mail" id="unique" size="45"><br/><br/>
<input type="password" placeholder="Password" id="secret" size="45"><br/><br/>
<input type="text" placeholder="Gender" id="gender" size="45"><br/><br/>
<div class="ui checkbox">
<input type="checkbox" tabindex="0" class="hidden">
<label>I agree to the Terms and Conditions</label>
</div>
<div class="ui button" id="signup">Sign up</div>
</div>
</form>
</div>
<div class="signup">
<p style="text-align:center;">Not your first time? <a href="login.html">Sign up</a></p>
</div>
<script src="js/jquery-2.2.3.min.js"></script>
<script>
$(document).ready(function(){
$("#signup").click(function(){
var name = $("#name").val();
var username = $("#username").val();
var email = $("#unique").val();
var password = $("#secret").val();
var gender = $("#gender").val();
if (name != "" && username != "" && email != "" && password != "" && gender != "") {
$.ajax({
type: 'post',
url: 'http://gothere.000webhostapp.com/signup.php',
//url: 'signup.php',
data: {
name: name,
username: username,
email: email,
password: password,
gender: gender
},
success:function(response) {
if (response == "success") {
//$('#test').html(response);
alert("Sign up successful log in to continue");
window.location.href="login.html";
}
else {
alert("Sign up unsuccessful");
}
}
});
}
else {
alert("Fill all fields");
}
});
});
</script>
</body>
</html>