-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathindex.html
More file actions
150 lines (133 loc) · 3.29 KB
/
Copy pathindex.html
File metadata and controls
150 lines (133 loc) · 3.29 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
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Login Page</title>
<style>
body {
font-family: Arial, sans-serif;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
margin: 0;
background-color: #c89595;
background-image: url(bac3.jpg);
}
#outer-container {
display: flex;
max-width: 800px;
}
#image-container {
flex: 1;
text-align: center;
}
#image-container img {
max-width: 100%;
border-radius: 8px;
}
#login-container {
flex: 1;
background-color: #f6f1f1;
padding: 20px;
border-radius: 8px;
box-shadow: 0 10px 10px rgba(0, 0, 0, 0.1);
text-align: center;
animation: fadeIn 0.5s;
}
#form-container {
padding: 0 20px;
text-align: center;
}
h1 {
color: #333;
font-size: 24px;
}
input {
width: 75%;
padding: 10px;
margin: 10px 0;
box-sizing: border-box;
border: 1px solid #ccc;
border-radius: 20px;
box-shadow: 10px 10px 10px grey;
}
button {
background-color: #4caf50;
color: #fff;
padding: 10px 20px;
border: none;
border-radius: 20px;
cursor: pointer;
}
button:hover {
background-color: #45a049;
}
#loading-spinner {
display: none;
margin-top: 20px;
}
@keyframes fadeIn {
from {
opacity: 0;
}
to {
opacity: 1;
}
}
</style>
</head>
<body>
<div id="outer-container">
<div id="image-container">
<img src="vintage _ aesthetic _ book _ flowers _ antique _ mood _ moodboard _ delicate flowers.jpeg">
</div>
<div id="login-container">
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<h1>Login Here</h1>
<p>Login your account with username and password </p>
<form id="login-form">
<div id="form-container">
<input type="text" id="username" placeholder="Username" required>
<br><br>
<input type="password" id="password" placeholder="Password" required>
<br>
<br>
<br>
<button type="button" onclick="login()">Login</button>
<!-- Add a loading spinner -->
<div id="loading-spinner">
<img src="Spinner-1s-112px.gif" alt="Loading..." width="50">
</div>
</div>
</form>
</div>
</div>
<script>
function login() {
const username = document.getElementById('username').value;
const password = document.getElementById('password').value;
const loadingSpinner = document.getElementById('loading-spinner');
const loginButton = document.querySelector('button');
// Show loading spinner
loadingSpinner.style.display = 'inline-block';
// Hide login button
loginButton.style.display = 'none';
// Simulate login process (in a real scenario, you would make an API call here)
setTimeout(() => {
// Hide loading spinner after 2 seconds
loadingSpinner.style.display = 'none';
// Redirect to the main homepage (mainhomepage.html) upon successful login
window.location.href = './trans.html';
}, 3000); // 2 seconds delay
}
</script>
</body>
</html>