2023-04-15 14:02:44 +00:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html lang="en">
|
|
|
|
|
|
|
|
<head>
|
|
|
|
<meta charset="UTF-8" />
|
|
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
|
|
<title>WIP Uploader</title>
|
|
|
|
|
|
|
|
<script src="https://cdn.fascinated.cc/assets/tailwindcss/3.2.4.js"></script>
|
2023-04-15 17:27:51 +00:00
|
|
|
<script src="https://cdn.fascinated.cc/assets/sweetalert2.all.min.js"></script>
|
2023-04-15 17:14:47 +00:00
|
|
|
|
|
|
|
<meta property="og:type" content="website" />
|
|
|
|
<meta property="og:title" content="WIP Maps" />
|
2023-04-15 17:15:47 +00:00
|
|
|
<meta property="og:description" content="Simple website to host WIP BeatSaber maps" />
|
2023-04-15 17:14:47 +00:00
|
|
|
<meta property="og:url" content="https://wip.fascinated.cc" />
|
|
|
|
<meta name="twitter:card" content="summary_large_image" />
|
|
|
|
<meta name="twitter:title" content="WIP Maps" />
|
2023-04-15 17:15:47 +00:00
|
|
|
<meta name="twitter:description" content="Simple website to host WIP BeatSaber maps" />
|
2023-04-15 17:14:47 +00:00
|
|
|
<meta property="theme-color" content="#4d3a9c" />
|
|
|
|
|
2023-04-15 17:36:17 +00:00
|
|
|
<script>
|
|
|
|
function copy() {
|
|
|
|
navigator.clipboard.writeText("!wip <?php echo $_GET["map"]; ?>");
|
|
|
|
Swal.fire({
|
|
|
|
icon: "success",
|
|
|
|
title: "Copied to clipboard",
|
|
|
|
showConfirmButton: false,
|
|
|
|
timer: 1000
|
|
|
|
});
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
|
2023-04-15 14:02:44 +00:00
|
|
|
</head>
|
|
|
|
|
|
|
|
<body>
|
|
|
|
<div class="flex items-center justify-center h-screen bg-gray-900">
|
|
|
|
<div class="w-1/2">
|
|
|
|
<div class="bg-gray-800 rounded-lg shadow-xl p-10">
|
2023-04-15 17:45:23 +00:00
|
|
|
<h2 class="text-3xl font-bold text-white mb-1.5">
|
2023-04-15 14:02:44 +00:00
|
|
|
WIP Map Uploader
|
|
|
|
</h2>
|
2023-04-15 17:40:52 +00:00
|
|
|
|
2023-04-15 17:45:23 +00:00
|
|
|
<p class="text-lg text-white mb-1.5">
|
2023-04-15 17:40:52 +00:00
|
|
|
Max File Size: 100MB (Cloudflare Limit)
|
|
|
|
</p>
|
2023-04-15 17:45:23 +00:00
|
|
|
<p class="text-lg text-gray-400 mb-6">
|
|
|
|
Note: Files will be automatically deleted after 30 minutes
|
|
|
|
</p>
|
2023-04-15 14:02:44 +00:00
|
|
|
<?php
|
|
|
|
// if the map parameter is set, display the map
|
|
|
|
if (isset($_GET["map"])) {
|
2023-04-15 17:22:11 +00:00
|
|
|
echo
|
|
|
|
'
|
|
|
|
<div class="mb-5">
|
|
|
|
<label for="map" class="block text-white text-sm font-bold mb-2">Successfully uploaded Map</label>
|
|
|
|
<span class="bg-gray-700 text-white rounded w-full py-2 px-3 focus:outline-none focus:shadow-outline">!wip ' . $_GET["map"] . '</span>
|
2023-04-15 17:29:45 +00:00
|
|
|
<button class="bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded focus:outline-none focus:shadow-outline" onclick="copy()">Copy</button>
|
2023-04-15 17:22:11 +00:00
|
|
|
</div>
|
|
|
|
';
|
|
|
|
return;
|
2023-04-15 14:02:44 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// if the map parameter is not set, display the upload form
|
2023-04-15 17:22:11 +00:00
|
|
|
echo
|
|
|
|
'
|
|
|
|
<form action="upload.php" method="post" enctype="multipart/form-data">
|
|
|
|
<div class="mb-5">
|
|
|
|
<label for="map" class="block text-white text-sm font-bold mb-2">Map</label>
|
|
|
|
<input type="file" name="map" id="map" class="bg-gray-700 text-white rounded w-full py-2 px-3 focus:outline-none focus:shadow-outline">
|
|
|
|
</div>
|
|
|
|
<div class="mb-5">
|
|
|
|
<button type="submit" class="bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded focus:outline-none focus:shadow-outline">Upload</button>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
';
|
2023-04-15 14:02:44 +00:00
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</body>
|
|
|
|
|
|
|
|
</html>
|