-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathcreate-account.html
More file actions
63 lines (57 loc) · 2.66 KB
/
Copy pathcreate-account.html
File metadata and controls
63 lines (57 loc) · 2.66 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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>SSN:Create Account</title>
<link rel="stylesheet" href="assets/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" href="assets/fonts/ionicons.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.5.2/animate.min.css">
<link rel="stylesheet" href="assets/css/Login-Form-Dark.css">
<link rel="stylesheet" href="assets/css/styles.css">
</head>
<body>
<div class="login-dark">
<form method="post">
<h2 class="sr-only">SignUp Form</h2>
<div class="illustration"><i class="icon ion-ios-locked-outline"></i></div>
<div class="form-group">
<input class="form-control" type="text" id="username" name="username" placeholder="username">
</div>
<div class="form-group">
<input class="form-control" type="email" name="email" id="email" placeholder="Email">
</div>
<div class="form-group">
<input class="form-control" type="password" name="password" id="password" placeholder="Password">
</div>
<div class="form-group">
<button class="btn btn-primary btn-block" id="ca" type="button" data-bs-hover-animate="shake">Sign Up</button>
</div><a href="/SushiNetwork/login.php" class="forgot">Already got an account? Click here!</a></form>
</div>
<script src="assets/js/jquery.min.js"></script>
<script src="assets/bootstrap/js/bootstrap.min.js"></script>
<script>
$('#ca').click(function() {
$.ajax({
type: "POST",
url: "api/users",
processData: false,
contentType: "application/json",
data: '{ "username": "' + $("#username").val() + '","email": "' + $("#email").val() + '","password": "' + $("#password").val() + '" }',
success: function(r) {
console.log(r);
alert(r); // 3shan 3aadel
},
error: function(r) {
setTimeout(function() {
$('[data-bs-hover-animate]').removeClass('animated ' + $('[data-bs-hover-animate]').attr('data-bs-hover-animate'));
}, 2000)
$('[data-bs-hover-animate]').addClass('animated ' + $('[data-bs-hover-animate]').attr('data-bs-hover-animate'))
console.log(r)
alert("something is wrong with entered data");
}
});
});
</script>
</body>
</html>