This repository was archived by the owner on Oct 13, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
462 lines (377 loc) · 25.2 KB
/
index.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
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
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Wings of Fire: The New World - Minecraft Server</title>
<script type="application/ld+json">
{
"@context" : "https://schema.org",
"@type" : "WebSite",
"name" : "Wings of Fire: The New World - Minecraft Server",
"url" : "https://woftnw.com/"
}
</script>
<link rel="stylesheet" href="style.css">
<!-- og meta -->
<meta property="og:type" value="website" />
<meta property="og:title" value="Wings of Fire: The New World" />
<meta property="og:description" value="Wings of Fire: The New World is a community-driven Minecraft: Java Edition server based on the Wings of Fire series of novels." />
<meta property="og:url" value="https://woftnw.org" />
<meta property="og:image" value="https://lh3.googleusercontent.com/fife/ALs6j_EHtZRDJuoSzNA5a3b-5ixrI0hwj8rSJKdAeOsls5avOEhoJ7GLhPONLv4jFrDyTsxzxcFAj9bvpO-mlTgPYE7pLHBeqB7RnsiDqUrl0JElHVi5udesnnkseJgmlsZ6ofwNTcYmSym-twkLx2bCxSJHlEeOPSFe8w0Fq21CzjHDjMjilF4VBJl7xnEKaMz1RM0DpmgRnDa8QAt46eEZdai8vXufl8BgZdyrjo2IBb9c6fJWB0N8cqmd-y2yvHdZIdfvdikt58LVQSolJKDNyZAHcDrJax00FqwtPVfyFUh43U7bcqpTCElGzBnR7nOBYhSP_MmhaTb9EJEd93FOj_q57Nn0vZWk0tgJzKbZ5gDwOZh_VQnvLyvR2XlFbmJ0zOw-hMAxj18gItJ13KdMsEOwuxRLGoqZ2nGxMRBxnPanVhE4fdTXGU5fIw32P9yHo9c3EEDZsYftLZyTgin7IGzoaPyStLuXKkhCA0OinJuZGZh1ZBN30acs3oCQFHJ3rCkd0IDe-bPsjYSJ3FfVVli6Xc5QNuiFANZzYQ1AnBDmcSs_hXH5LEAvW_935B9XGIydSN4noFRHqm91BIM5wqs9tyQWzepBhWArTldOnn_aZ9elJ2jzGQ4ILB-z0dU_zNFBGK8Mriy-4QLEw1RgC_duxWsuBkBixBhCuphuIitFVLKceRpsL4t-DmNqR2C58XAWm_PDZy0RiVq7e-omm03zE66dx9qTF6JrdvSEt36zdZC85SnPniQr-AafceJeXIzl2Kd2IOUI-FdueOs_a8Ok4hXdhVw9PZ0yAimd3TPOQ7R_55UR2HNtsLhKUmeLCNlMqnECkgdlAg74HI-3dndNQvBNZeDxlaSBW_qP9vx1-RmGnyS6gUHWSeGJUJ5H_ghdZOzv3QrkBdd4USAONOfHMJvx4nJOMyIkj8G7kwAWQZg9_hbo1vt5vtYT0wcG21vQx_MuJoza9NUZzHBZFqEVZuQm9DWJwEH_-VXYPJmY9j8DVtOFdnHzkOhGMgMTix45hHuvpHzvxOD884eql0N-7_AYbYWLBJilHAdlNoZ5ADnpjoVSkBViZX4ffb-Cu-xVwEh17HsIVzSgWH2G5DTy6FLGjfk1Uyb0JVVMtgFJN9giT4wg7W0ctMMU9DaSyIyX_20yk6wVlQR2KcCQUvE7lNUnEpcKITqYOoFmYAxwo3IHo2X0V2oEAXcsh3WGOzqBnEdq6D0A7bWbh61sGauYviWyFbzHyXZIwaNcqWvGq6_YQq480uRA8qurPH9jsuRqYJd_jrRtl61nJ7hCkuZANrpyzV1W7K2rIpwTGIfLIL5QKyFVjlqmVeR-G0NY8b7vU70IDqnUaPKCdQrvcvV9ZhpwVygP8hD9drnCYGf6MCBF-YDTQJ-qII3HDQq8pS9JCIKbZI_VTUWJHAFbm8htOC2TKBZtieTFE_TIJJp-NGln1BcjpFp4kYqHHnac9E13UK-4jN9s4ClG5bhQP52tfn3uy712a0XZ3Sg0IztM8iizZZWJNiIFEw1SI83UlROoNC8Uqe2Xla70vaYNrFcskZHQ4zASg44lt950w57AQtgaIYv7Wttj2z-kICRCN-cnmK-zyREVioSwuEihutO-qhqZdFGQzQcuC8t4mZQY2vACYzDAEj6xASdiuVYVr4n-ih11WGuYnVX-QVL2pCuNkk045c-nIeGPy0GuhTXyDLHy35bTTGlRGH9RC0aK8TnpedeQHI4YMRLjmu2A7aoGjoBhuoZcB3OaAg=w1445-h889" />
<meta property="og:image:width" value="1920" />
<meta property="og:image:height" value="1080" />
<!-- twitter meta -->
<meta name="twitter:card" value="summary_large_image" />
<meta name="twitter:title" value="Wings of Fire: The New World" />
<meta name="twitter:description" value="Wings of Fire: The New World is a community-driven Minecraft: Java Edition server based on the Wings of Fire series of novels." />
<meta name="twitter:image" value="https://lh3.googleusercontent.com/fife/ALs6j_EHtZRDJuoSzNA5a3b-5ixrI0hwj8rSJKdAeOsls5avOEhoJ7GLhPONLv4jFrDyTsxzxcFAj9bvpO-mlTgPYE7pLHBeqB7RnsiDqUrl0JElHVi5udesnnkseJgmlsZ6ofwNTcYmSym-twkLx2bCxSJHlEeOPSFe8w0Fq21CzjHDjMjilF4VBJl7xnEKaMz1RM0DpmgRnDa8QAt46eEZdai8vXufl8BgZdyrjo2IBb9c6fJWB0N8cqmd-y2yvHdZIdfvdikt58LVQSolJKDNyZAHcDrJax00FqwtPVfyFUh43U7bcqpTCElGzBnR7nOBYhSP_MmhaTb9EJEd93FOj_q57Nn0vZWk0tgJzKbZ5gDwOZh_VQnvLyvR2XlFbmJ0zOw-hMAxj18gItJ13KdMsEOwuxRLGoqZ2nGxMRBxnPanVhE4fdTXGU5fIw32P9yHo9c3EEDZsYftLZyTgin7IGzoaPyStLuXKkhCA0OinJuZGZh1ZBN30acs3oCQFHJ3rCkd0IDe-bPsjYSJ3FfVVli6Xc5QNuiFANZzYQ1AnBDmcSs_hXH5LEAvW_935B9XGIydSN4noFRHqm91BIM5wqs9tyQWzepBhWArTldOnn_aZ9elJ2jzGQ4ILB-z0dU_zNFBGK8Mriy-4QLEw1RgC_duxWsuBkBixBhCuphuIitFVLKceRpsL4t-DmNqR2C58XAWm_PDZy0RiVq7e-omm03zE66dx9qTF6JrdvSEt36zdZC85SnPniQr-AafceJeXIzl2Kd2IOUI-FdueOs_a8Ok4hXdhVw9PZ0yAimd3TPOQ7R_55UR2HNtsLhKUmeLCNlMqnECkgdlAg74HI-3dndNQvBNZeDxlaSBW_qP9vx1-RmGnyS6gUHWSeGJUJ5H_ghdZOzv3QrkBdd4USAONOfHMJvx4nJOMyIkj8G7kwAWQZg9_hbo1vt5vtYT0wcG21vQx_MuJoza9NUZzHBZFqEVZuQm9DWJwEH_-VXYPJmY9j8DVtOFdnHzkOhGMgMTix45hHuvpHzvxOD884eql0N-7_AYbYWLBJilHAdlNoZ5ADnpjoVSkBViZX4ffb-Cu-xVwEh17HsIVzSgWH2G5DTy6FLGjfk1Uyb0JVVMtgFJN9giT4wg7W0ctMMU9DaSyIyX_20yk6wVlQR2KcCQUvE7lNUnEpcKITqYOoFmYAxwo3IHo2X0V2oEAXcsh3WGOzqBnEdq6D0A7bWbh61sGauYviWyFbzHyXZIwaNcqWvGq6_YQq480uRA8qurPH9jsuRqYJd_jrRtl61nJ7hCkuZANrpyzV1W7K2rIpwTGIfLIL5QKyFVjlqmVeR-G0NY8b7vU70IDqnUaPKCdQrvcvV9ZhpwVygP8hD9drnCYGf6MCBF-YDTQJ-qII3HDQq8pS9JCIKbZI_VTUWJHAFbm8htOC2TKBZtieTFE_TIJJp-NGln1BcjpFp4kYqHHnac9E13UK-4jN9s4ClG5bhQP52tfn3uy712a0XZ3Sg0IztM8iizZZWJNiIFEw1SI83UlROoNC8Uqe2Xla70vaYNrFcskZHQ4zASg44lt950w57AQtgaIYv7Wttj2z-kICRCN-cnmK-zyREVioSwuEihutO-qhqZdFGQzQcuC8t4mZQY2vACYzDAEj6xASdiuVYVr4n-ih11WGuYnVX-QVL2pCuNkk045c-nIeGPy0GuhTXyDLHy35bTTGlRGH9RC0aK8TnpedeQHI4YMRLjmu2A7aoGjoBhuoZcB3OaAg=w1445-h889" />
</head>
<div id="inspector">
<img hidden src="screenshots/2023-08-02_12.27.27.png" alt="The RainWing village.">
<button hidden onclick="uninspect()"></button>
</div>
<body>
<div class="banner">
<video autoplay plays inline muted loop id="backgroundVideo">
<source src="showcase.mp4" type="video/mp4">
</video>
<img id="bannerimg" src="wordmark.png" alt="Wings of Fire: The New World">
</div>
<div class="alt-background">
<div class="content">
<h2 class="headline"><b>Wings of Fire: The New World</b> is a community-driven Minecraft: Java Edition
server
based on the <i>Wings of Fire</i> series of novels.</h2>
<br>
<div class="button-line">
<a href="https://discord.woftnw.org" target="_blank">
<button class="button-primary">
Join the Discord server
</button>
</a>
<button class="button-secondary" onclick="revealWhitelist()" onkeydown="revealWhitelist()">
Don't have Discord?
</button>
</div>
<div style="display: flex; width: 550px; max-width: 100% ; justify-content: center; margin: 0 auto;">
<div id="whitelistInput" class="name-input">
<input type="text" placeholder=""
style="transition: height 0.3s; height: 0px; background-color: transparent;"
onfocus="tryWhitelist()">
<button class="sendButton" onclick="sendUsername()" onkeydown="sendUsername()">
<img src="paper-plane-solid.svg" alt="Send">
</button>
</div>
</div>
<div class="headline">
<p class="whitelist-message" id="success"><b>You have been successfully whitelisted!</b> You can join in
Minecraft by adding a new server with the address <code>play.woftnw.org</code>.</p>
<p class="whitelist-message" id="failure"><b>Something went wrong.</b> Make sure you've typed your
username
exactly as shown in the buttom-right corner of the Minecraft launcher. You need to have a paid
Minecraft: Java Edition account to join.</p>
<p class="whitelist-message" id="disabled"><b>This has been temporarily disabled.</b> Sorry! Web
whitelist has been temporarily disabled to fix some bugs. :( Join the Discord server or try again
later.</p>
</div>
</div>
</div>
<div class="main-background">
<div class="content">
<h1>Welcome to the World of Wings of Fire!</h1>
<p>Wings of Fire: The New World is a Minecraft: Java Edition dedicated server that aims to create the world of Wings of Fire in a large-scale, player-interactive experience.</p>
<p>The server began in March 2016 by ebelle. It started as a small whitelisted community branching off of the Wings of Fire Fanon Wiki. The map, currently in its fourth iteration, is custom-made to recreate Pyrrhia and Pantala from <i>Wings of Fire</i>. The server's story is set thousands of years following the canon events of the book series and boasts a unique cast of characters and an extensive new world full of lore to explore!</p>
<p>The world has grown from <b>under 600 blocks</b> across to <b>nearly 10,000</b>.<br>
The staff team has grown from <b>one person</b> to <b>over twenty</b>.<br>
The community has grown from about <b>thirty-five members</b> to <b>well over a thousand</b>.</p>
<p><b>Check out what we've created!</b></p>
<hr>
<div class="sidebyside">
<div class="secondary-background">
<img class="inspectable" onclick="inspect(this)" src="screenshots/2023-08-02_12.27.27.png" alt="The RainWing village.">
<p class="caption">RainWing Village</p>
</div>
<div>
<h3>The World of Wings of Fire</h3>
<p>Wings of Fire: The New World is currently the <b>largest</b> and <b>most complete</b> 3D
recreation
of Pyrrhia and Pantala from <i>Wings of Fire</i>, and it's entirely open for your creation!</p>
</div>
</div>
<hr>
<div class="sidebyside">
<div>
<h3>Elytras of Fire</h3>
<p>Elytras of Fire introduces three series-inspired and all-new abilities for each tribe. Get unique
powers and abilities depending on which tribe you choose to play!</p>
</div>
<div class="secondary-background">
<img class="inspectable" onclick="inspect(this)" src="screenshots/2023-07-28_11.57.32.png" alt="Jewel Hive">
<p class="caption">A view of Jewel Hive</p>
</div>
</div>
<hr>
<div class="sidebyside">
<div class="secondary-background">
<img class="inspectable" onclick="inspect(this)" src="screenshots/2023-08-29_15.04.17.png" alt="The Hub">
<p class="caption">The Hub</p>
</div>
<div>
<h3>Eye of Onyx</h3>
<p>Wings of Fire: The New World features the Eye of Onyx royalty system, which allows you to climb the ranks and become
ruler of a kingdom! Challenge your superiors and compete in a mini-game to rise up the ranks and
become the ruler of a kingdom.</p>
</div>
</div>
<h2>We also have all this neat stuff!</h2>
<ul>
<li>Absolutely no pay walled content</li>
<li>Advanced personal build protection</li>
<li>Toggle player combat on and off at will</li>
<li>10 custom cakes</li>
<li>25 custom berries</li>
<li>Dozens of custom elytra variants</li>
<li>A fair economy system</li>
<li>Easy shop creation</li>
<li>Discord and in-game PluralKit</li>
<li>Sit, lay, crawl, and spin</li>
<li>Unique events</li>
<li>In-game role-play & character system</li>
<li>Kind, capable, and helpful staff</li>
<li>Discord chat bridge</li>
<li>Discord Starboard</li>
<li>The Block Pit resource farm</li>
<li>The Instasmelter instant furnace</li>
<li>And even more!</li>
</ul>
<hr>
<h3 class="headline">We've come a long way from a small server, having grown into the flourishing, ever-growing community we are today. Our staff team has continued to cultivate the server, allowing future generations of young readers to partake in a fun, safe server that they can enjoy. All staff on the server are volunteers and are very passionate about keeping both the Discord and Minecraft communities safe.</h3>
<div class="secondary-background">
<img class="inspectable" onclick="inspect(this)" src="screenshots/Pyrrhia (Medium).png" alt="Map of Pyrrha" style="width: unset;">
<p class="caption">Pyrrhia - 9856 x 8448 blocks</p>
</div>
<p></p>
<div class="secondary-background">
<img class="inspectable" onclick="inspect(this)" src="screenshots/Pantala (Medium).png" alt="Map of Pantala" style="width: unset;">
<p class="caption">Pantala - 5760 x 2632 blocks</p>
</div>
<h2>Want to see more? Check out our YouTube channel</h2>
<div class="videoContainer">
<iframe class="video" src="https://www.youtube.com/embed/OHgi3QG5C0w?si=Tm-YtHl4YpooP3XD"
title="YouTube video player"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
allowfullscreen></iframe>
</div>
<div class="sidebyside">
<div class="videoContainer">
<iframe class="video" src="https://www.youtube.com/embed/m3oFmJAB9oY?si=rOZW7I0H49o7xc5t"
title="YouTube video player"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
allowfullscreen></iframe>
</div>
<div class="videoContainer">
<iframe class="video" src="https://www.youtube.com/embed/iYTKLDFH6u0?si=9Tvt68_Bn8jLmEAW"
title="YouTube video player"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
allowfullscreen></iframe>
</div>
</div>
<div class="sidebyside">
<iframe class="discord-embed" title="Discord"
src="https://discord.com/widget?id=658004601869565962&theme=dark" width="350" height="500"
sandbox="allow-popups allow-popups-to-escape-sandbox allow-same-origin allow-scripts"></iframe>
<div>
<h3>Join the Community</h3>
<p>We have a wonderful, inviting, and vibrant community that has steadily been growing. We use Discord as our primary communication platform for announcements, events, and chatting!</p>
<p>Note that, per Discord's <a href="https://discord.com/terms/">Terms of Service</a>, you must
be
at
least 13 years old or have the consent of
your parent or guardian to create a Discord account.</p>
</div>
</div>
</div>
</div>
<div class="alt-background">
<div class="content">
<h2 class="headline" style="margin: 10px 0 0;">Interested in joining?</h2>
<p class="headline">Our server requires your username to be added to a whitelist to be able to join. We
recommend you
join the Discord server to really get into the community, but you can also input your name here if you
want.
</p>
<div class="button-line" style="margin: 0 0 20px;">
<a href="https://discord.woftnw.org" target="_blank">
<button class="button-primary">
Join the Discord server
</button>
</a>
<button class="button-secondary" onclick="revealWhitelist()" onkeydown="revealWhitelist()">
Don't have Discord?
</button>
</div>
</div>
</div>
<div class="main-background">
<div class="content">
<code
class="disclaimer">Wings of Fire: The New World is not affiliated with, endorsed by, or sponsored by Tui T. Sutherland, the author of Wings of Fire, or any entities associated with her. Wings of Fire and all related characters, locations, and elements are the intellectual property of Tui T. Sutherland. All rights to Wings of Fire and its content are exclusively owned by Tui T. Sutherland and her authorized publishers.
<br><br>
Wings of Fire: The New World and related assets are for entertainment purposes only. Any references to Wings of Fire, its characters, locations, or any other elements from the series are made with utmost respect to the original work. No infringement of copyright is intended.
<br><br>
All names, characters, places, and events referenced within Wings of Fire: The New World are used fictitiously or for the purpose of commentary, criticism, or parody. Any resemblance to actual persons, living or dead, or actual events is purely coincidental.
<br><br>
If you wish to explore or engage with the official Wings of Fire content, please visit authorized retailers or platforms where Tui T. Sutherland's work is officially represented.
<br><br>
We, the Wings of Fire: The New World administration, disclaim any responsibility for the misuse or misrepresentation of the content within Wings of Fire: The New World or any related assets. Users are encouraged to respect the intellectual property rights of Tui T. Sutherland and adhere to all relevant laws and regulations.
<br><br>
For inquiries regarding the use of Wings of Fire content, please contact the appropriate rights holders.</code>
</div>
</div>
<footer>
<div>
<p><b>© 2024 <a href="https://woftnw.org">Wings of Fire: The New World</b></a></p>
</div>
<div class="footer-links">
<p><a href="https://discord.woftnw.org" , target="_blank">Discord</a></p>
<p><a href="https://youtube.com/@woftnw" , target="_blank">YouTube</a></p>
<p><a href="https://wof-the-new-world.tumblr.com/", target="_blank">Tumblr</a></p>
<p><a href="https://woftnw.redbubble.com/" , target="_blank">Redbubble</a></p>
<p><a href="https://www.patreon.com/woftnw" , target="_blank">Patreon</a></p>
<p><a href="https://wiki.woftnw.org" , target="_blank">Wiki</a></p>
<p><a href="mailto:[email protected]">Contact</a></p>
</div>
<br>
</footer>
<script>
function inspect(element) {
const inspector = document.getElementById("inspector")
inspector.style.width = "100svw";
inspector.style.height = "100svh";
inspector.style.backgroundColor = "#00000055";
inspector.children[0].src = element.src;
inspector.children[0].hidden = false;
inspector.children[0].style.backgroundColor = "rgba(255, 255, 255, 1)";
inspector.children[1].hidden = false;
inspector.children[1].style.color = "rgba(255, 255, 255, 1)";
}
function uninspect() {
const inspector = document.getElementById("inspector")
inspector.style.width = "";
inspector.style.height = "";
inspector.style.backgroundColor = "";
inspector.children[0].hidden = true;
inspector.children[0].style.backgroundColor = "transparent";
inspector.children[1].hidden = true;
inspector.children[1].style.color = "transparent";
}
document.body.addEventListener('keydown', function(e) {
if (e.code === "Escape") { //checks whether the pressed key is "Escape"
uninspect();
}
});
document.addEventListener("DOMContentLoaded", function (event) {
const bannerimg = document.getElementById("bannerimg");
bannerimg.style.scale = 1;
});
document.getElementById("whitelistInput").children[0].addEventListener("keydown", function (e) {
if (e.code === "Enter") { //checks whether the pressed key is "Enter"
sendUsername();
}
});
function revealSuccessMessage() {
const message = document.getElementById("success");
message.style.height = "120px";
message.style.color = "white";
}
function revealFailureMessage() {
const message = document.getElementById("failure");
message.style.height = "120px";
message.style.color = "white";
}
function revealDisabledMessage() {
const message = document.getElementById("disabled");
message.style.height = "120px";
message.style.color = "white";
}
function revealWhitelist() {
const whitelistInput = document.getElementById("whitelistInput");
whitelistInput.hidden = false;
whitelistInput.children[0].style.height = "50px";
whitelistInput.style.height = "50px";
whitelistInput.style.margin = "50px auto 50px";
const y = whitelistInput.getBoundingClientRect().top + window.scrollY;
window.scroll({
top: y - 300,
behavior: 'smooth'
});
setTimeout(function () {
whitelistInput.style.backgroundColor = "white";
whitelistInput.style.width = "100%";
whitelistInput.children[0].style.display = "block";
whitelistInput.children[1].children[0].style.display = "block";
whitelistInput.children[0].style.width = "auto";
whitelistInput.children[1].children[0].style.fill = "blue";
whitelistInput.children[0].placeholder = "Put your username here!";
}, 250);
}
function tryWhitelist() {
const whitelistInput = document.getElementById("whitelistInput");
let send = document.createElement('img');
send.src = "paper-plane-solid.svg";
send.style.display = "block";
send.setAttribute("onclick", "sendUsername()");
whitelistInput.children[1].replaceWith(send);
const failureMessage = document.getElementById("failure");
failureMessage.style.height = "0px";
failureMessage.style.color = "transparent";
}
function sendUsername() {
const whitelistInput = document.getElementById("whitelistInput");
if (whitelistInput.children[0].value.length == 0) {
alert("You cannot send an empty value!")
} else {
whitelistInput.children[0].disabled = true;
let loader = document.createElement('div');
loader.classList.add("loader");
whitelistInput.children[1].replaceWith(loader);
// Send
var username = whitelistInput.children[0].value;
console.log("Username:", username);
// Make an HTTP POST request to your Spark API endpoint
fetch("https://whitelist.woftnw.org/process-username", {
method: "POST",
headers: {
"Content-Type": "application/x-www-form-urlencoded" // Set the appropriate content type
},
body: "username=" + encodeURIComponent(username)
})
.then(response => response.json())
.then(data => {
// Handle the response from the server
console.log(data);
let checkmark = document.createElement('p');
// You can show a success/failure message to the user based on the response
if (data.success) {
checkmark.innerHTML = "✅";
revealSuccessMessage();
} else {
checkmark.innerHTML = "❌";
whitelistInput.children[0].disabled = false;
revealFailureMessage();
}
checkmark.classList.add("checkmark");
whitelistInput.children[1].replaceWith(checkmark);
})
.catch(error => {
console.error("Error:", error);
// Handle errors, e.g., show an error message to the user
alert("An error occurred: " + error.name + "\n" + error.message + "\n\nThe server may be offline or inaccessable. Try again later.");
});
}
}
</script>
</body>
</html>