-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdiscord.html
78 lines (77 loc) · 3.29 KB
/
discord.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Discord Yönlendirme</title>
<link rel="stylesheet" href="style.css">
<link rel="shortcut icon" href="https://avatars.githubusercontent.com/u/140610717?s=200&v=4" type="image/x-icon">
</head>
<body class="dark">
<button class="theme">☾</button>
<center>
<b>Yönlendiriliyorsunuz</b>
<div class="txt">
placeTR Discord sunucu<br><br>
<input id="cancel" type="submit" value="İptal">
</div>
</center>
<script>
document.body.onload = function () {
setTimeout(function () {
window.location.href = "https://discord.gg/placeTR";
}, 2500)
}
document.querySelector("#cancel").addEventListener("click", function () {
window.location.href = "index.html";
})
function getCookie(name) {
var value = "; " + document.cookie;
var parts = value.split("; " + name + "=");
if (parts.length === 2) return parts.pop().split(";").shift();
}
function toggleTheme() {
var body = document.body;
var isDarkTheme = body.classList.contains("dark");
if (isDarkTheme) {
document.cookie = "theme=light";
} else {
document.cookie = "theme=dark";
}
}
if (getCookie("theme") !== null) {
document.body.classList.value = getCookie("theme");
if (getCookie("theme") === "light") {
document.querySelector(".horizontal-menu").style.backgroundColor = "white";
document.querySelector("#name").style.color = "black";
document.querySelector("#email").style.color = "black";
document.querySelector("#sub").style.color = "black";
document.querySelector("#body").style.color = "black";
document.querySelector("footer").style.backgroundColor = "white";
}
} else {
document.body.classList.value = "dark";
}
document.querySelector(".theme").addEventListener("click", function () {
toggleTheme();
if (document.body.classList.value === "dark") {
document.body.classList.value = "light";
document.querySelector(".horizontal-menu").style.backgroundColor = "white";
document.querySelector("#name").style.color = "black";
document.querySelector("#email").style.color = "black";
document.querySelector("#sub").style.color = "black";
document.querySelector("#body").style.color = "black";
document.querySelector("footer").style.backgroundColor = "white";
} else {
document.body.classList.value = "dark";
document.querySelector(".horizontal-menu").style.backgroundColor = "black";
document.querySelector("#name").style.color = "white";
document.querySelector("#email").style.color = "white";
document.querySelector("#sub").style.color = "white";
document.querySelector("#body").style.color = "white";
document.querySelector("footer").style.backgroundColor = "black";
}
})
</script>
</body>
</html>