add skeleton for server checker

This commit is contained in:
cobblesteve 2024-06-02 09:40:32 -05:00 committed by GitHub
commit 0ee38817a6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

53
server-checker.html Normal file
View file

@ -0,0 +1,53 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Servers</title>
<link rel="shortcut icon" href="assets/mc-logo.png" type="image/x-icon">
<link rel="stylesheet" href="home.css">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons+Round"
rel="stylesheet">
</head>
<body>
<ul>
<li><a style="margin-left: 5px;" href="index.html">Home</a></li>
<li><a href="clients.html">Clients</a></li>
<li><a href="worlds.html">Worlds</a></li>
<li><a href="packs.html">Resource Packs</a></li>
<li><a class="active" href="servers.html">Servers</a></li>
<li style="float: right;"><a href="https://github.com/cobblesteve01/Eaglercraft-Extras" target="_blank"><img src="assets/github.png" style="height: 25px; color: white;" alt=""></a></li>
</ul>
<h1 class="h1a">Eaglercraft server checker</h1>
<h1 class="h1d">(Add wss://)</h1>
<br>
<br>
<br>
<br>
<br>
<div class="inputContainer">
<input type="url" id="serverInput" onkeydown="if(event.key==='Enter') go()" size="25" class="inputText" autofocus="">
<button onclick="go()" class="inputGo">Go</button>
</div>
<br>
<br>
<br>
<div id="embed" class="server-embed" style="width: 50%; height: 145px; background-color: black;"><canvas width="981" height="145"></canvas></div>
<script type="text/javascript" src="/servers/embed.js"></script>
<script type="text/javascript">
function go() {
// Clear existing content in the embed container
document.getElementById("embed").innerHTML = "";
var userInput = document.getElementById("serverInput").value;
new ServerEmbed(document.getElementById("embed"), "50%").ping(userInput);
}
window.addEventListener("load", () => {
go();
});
</script>
</body>