-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
59 lines (54 loc) · 1.44 KB
/
index.html
File metadata and controls
59 lines (54 loc) · 1.44 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
<!DOCTYPE html>
<html>
<head>
<title>输入服务器地址</title>
<style>
body {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
font-family: Arial, sans-serif;
background: linear-gradient(to bottom, #00ccff, #005fcc);
}
.container {
text-align: center;
}
.input-container {
margin-bottom: 20px;
}
.input-container input {
padding: 10px;
font-size: 16px;
border: 1px solid #ccc;
border-radius: 4px;
width: 300px;
}
.input-container button {
padding: 10px 20px;
font-size: 16px;
background-color: #4CAF50;
color: white;
border: none;
border-radius: 4px;
cursor: pointer;
}
</style>
</head>
<body>
<div class="container">
<h1>请输入服务器地址</h1>
<div class="input-container">
<input type="text" id="Input" placeholder="服务器IP/域名 + 端口">
</div>
<button onclick="save()">确认</button>
</div>
<script>
function save() {
var Text = document.getElementById("Input").value;
localStorage.setItem("serverAddress", Text);
window.location.href = "chat.html";
}
</script>
</body>
</html>