Spaces:
Running
Running
Commit ·
b05b4ac
1
Parent(s): 0bcdffe
Web
Browse files- Ark ReCode/index.html +73 -0
- script.js → Ark ReCode/script.js +0 -0
- style.css → Ark ReCode/style.css +0 -0
- index.html +64 -59
Ark ReCode/index.html
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!DOCTYPE html>
|
| 2 |
+
<html lang="id">
|
| 3 |
+
<head>
|
| 4 |
+
<meta charset="UTF-8">
|
| 5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>Ark Re Code Scraper</title>
|
| 7 |
+
<link rel="stylesheet" href="style.css">
|
| 8 |
+
</head>
|
| 9 |
+
<body>
|
| 10 |
+
<div class="container">
|
| 11 |
+
<h1>Ark Re Code Scraper</h1>
|
| 12 |
+
|
| 13 |
+
<label for="charName">Cari Karakter:</label>
|
| 14 |
+
<input type="text" id="charName" placeholder="Masukkan nama karakter...">
|
| 15 |
+
<button onclick="fetchData()">Cari</button>
|
| 16 |
+
|
| 17 |
+
<div id="result"></div>
|
| 18 |
+
</div>
|
| 19 |
+
|
| 20 |
+
<script>
|
| 21 |
+
async function fetchData() {
|
| 22 |
+
const charName = document.getElementById("charName").value;
|
| 23 |
+
const resultDiv = document.getElementById("result");
|
| 24 |
+
|
| 25 |
+
if (!charName) {
|
| 26 |
+
resultDiv.innerHTML = "<p>Masukkan nama karakter terlebih dahulu!</p>";
|
| 27 |
+
return;
|
| 28 |
+
}
|
| 29 |
+
|
| 30 |
+
try {
|
| 31 |
+
const response = await fetch(`http://localhost:3000/api?name=${charName}`);
|
| 32 |
+
const data = await response.json();
|
| 33 |
+
|
| 34 |
+
if (data.error) {
|
| 35 |
+
resultDiv.innerHTML = `<p>${data.error}</p>`;
|
| 36 |
+
return;
|
| 37 |
+
}
|
| 38 |
+
|
| 39 |
+
let output = "<h2>Hasil Pencarian:</h2>";
|
| 40 |
+
|
| 41 |
+
if (data.skills) {
|
| 42 |
+
output += `<h3>Skill & Discipline</h3>`;
|
| 43 |
+
output += `<p>Karakter: ${data.skills.Karakter}</p>`;
|
| 44 |
+
output += `<p>Link Skill 3: <a href="${data.skills.Skill3}" target="_blank">${data.skills.Skill3}</a></p>`;
|
| 45 |
+
output += `<p>Link Idle + Tap: <a href="${data.skills.Tap}" target="_blank">${data.skills.Tap}</a></p>`;
|
| 46 |
+
}
|
| 47 |
+
|
| 48 |
+
if (data.story) {
|
| 49 |
+
output += `<h3>Story Part II</h3>`;
|
| 50 |
+
output += `<p>Member: ${data.story.Member}</p>`;
|
| 51 |
+
output += `<p>Video: <a href="${data.story.Video}" target="_blank">${data.story.Video}</a></p>`;
|
| 52 |
+
}
|
| 53 |
+
|
| 54 |
+
if (data.chatAnimations) {
|
| 55 |
+
output += `<h3>Chat Animations</h3>`;
|
| 56 |
+
output += `<p>Karakter: ${data.chatAnimations.Karakter}</p>`;
|
| 57 |
+
output += `<p>Video: <a href="${data.chatAnimations.Video}" target="_blank">${data.chatAnimations.Video}</a></p>`;
|
| 58 |
+
}
|
| 59 |
+
|
| 60 |
+
if (data.illustration) {
|
| 61 |
+
output += `<h3>Illustrations</h3>`;
|
| 62 |
+
output += `<p>Karakter: ${data.illustration.Karakter}</p>`;
|
| 63 |
+
output += `<img src="${data.illustration.Image}" alt="Illustration" width="300">`;
|
| 64 |
+
}
|
| 65 |
+
|
| 66 |
+
resultDiv.innerHTML = output;
|
| 67 |
+
} catch (error) {
|
| 68 |
+
resultDiv.innerHTML = "<p>Gagal mengambil data.</p>";
|
| 69 |
+
}
|
| 70 |
+
}
|
| 71 |
+
</script>
|
| 72 |
+
</body>
|
| 73 |
+
</html>
|
script.js → Ark ReCode/script.js
RENAMED
|
File without changes
|
style.css → Ark ReCode/style.css
RENAMED
|
File without changes
|
index.html
CHANGED
|
@@ -1,73 +1,78 @@
|
|
| 1 |
<!DOCTYPE html>
|
| 2 |
-
<html lang="
|
| 3 |
<head>
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
<div id="result"></div>
|
| 18 |
-
</div>
|
| 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 |
-
output += `<p>Link Idle + Tap: <a href="${data.skills.Tap}" target="_blank">${data.skills.Tap}</a></p>`;
|
| 46 |
-
}
|
| 47 |
|
| 48 |
-
|
| 49 |
-
output += `<h3>Story Part II</h3>`;
|
| 50 |
-
output += `<p>Member: ${data.story.Member}</p>`;
|
| 51 |
-
output += `<p>Video: <a href="${data.story.Video}" target="_blank">${data.story.Video}</a></p>`;
|
| 52 |
-
}
|
| 53 |
|
| 54 |
-
|
| 55 |
-
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
}
|
| 59 |
|
| 60 |
-
|
| 61 |
-
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
|
|
|
|
|
|
|
|
|
| 65 |
|
| 66 |
-
resultDiv.innerHTML = output;
|
| 67 |
-
} catch (error) {
|
| 68 |
-
resultDiv.innerHTML = "<p>Gagal mengambil data.</p>";
|
| 69 |
-
}
|
| 70 |
-
}
|
| 71 |
-
</script>
|
| 72 |
</body>
|
| 73 |
</html>
|
|
|
|
| 1 |
<!DOCTYPE html>
|
| 2 |
+
<html lang="en">
|
| 3 |
<head>
|
| 4 |
+
<meta charset="UTF-8">
|
| 5 |
+
<title>Website Viewer</title>
|
| 6 |
+
<style>
|
| 7 |
+
body {
|
| 8 |
+
margin: 0;
|
| 9 |
+
font-family: sans-serif;
|
| 10 |
+
background-color: #121212;
|
| 11 |
+
color: #eee;
|
| 12 |
+
display: flex;
|
| 13 |
+
flex-direction: column;
|
| 14 |
+
height: 100vh;
|
| 15 |
+
}
|
|
|
|
|
|
|
|
|
|
| 16 |
|
| 17 |
+
header {
|
| 18 |
+
padding: 10px;
|
| 19 |
+
background-color: #1f1f1f;
|
| 20 |
+
display: flex;
|
| 21 |
+
gap: 10px;
|
| 22 |
+
align-items: center;
|
| 23 |
+
}
|
| 24 |
|
| 25 |
+
input[type="text"] {
|
| 26 |
+
flex: 1;
|
| 27 |
+
padding: 8px;
|
| 28 |
+
background-color: #2a2a2a;
|
| 29 |
+
color: #fff;
|
| 30 |
+
border: 1px solid #444;
|
| 31 |
+
border-radius: 4px;
|
| 32 |
+
}
|
| 33 |
|
| 34 |
+
button {
|
| 35 |
+
padding: 8px 12px;
|
| 36 |
+
background-color: #333;
|
| 37 |
+
color: white;
|
| 38 |
+
border: none;
|
| 39 |
+
border-radius: 4px;
|
| 40 |
+
cursor: pointer;
|
| 41 |
+
}
|
| 42 |
|
| 43 |
+
button:hover {
|
| 44 |
+
background-color: #555;
|
| 45 |
+
}
|
|
|
|
| 46 |
|
| 47 |
+
iframe {
|
| 48 |
+
flex: 1;
|
| 49 |
+
border: none;
|
| 50 |
+
width: 100%;
|
| 51 |
+
}
|
| 52 |
+
</style>
|
| 53 |
+
</head>
|
| 54 |
+
<body>
|
| 55 |
|
| 56 |
+
<header>
|
| 57 |
+
<input type="text" id="urlInput" placeholder="Masukkan URL (contoh: https://example.com)">
|
| 58 |
+
<button onclick="loadWebsite()">Load</button>
|
| 59 |
+
</header>
|
|
|
|
|
|
|
| 60 |
|
| 61 |
+
<iframe id="viewer" src=""></iframe>
|
|
|
|
|
|
|
|
|
|
|
|
|
| 62 |
|
| 63 |
+
<script>
|
| 64 |
+
function loadWebsite() {
|
| 65 |
+
const url = document.getElementById('urlInput').value;
|
| 66 |
+
const iframe = document.getElementById('viewer');
|
|
|
|
| 67 |
|
| 68 |
+
// Validasi dasar
|
| 69 |
+
if (url.startsWith('http://') || url.startsWith('https://')) {
|
| 70 |
+
iframe.src = url;
|
| 71 |
+
} else {
|
| 72 |
+
alert("Masukkan URL lengkap dengan http:// atau https://");
|
| 73 |
+
}
|
| 74 |
+
}
|
| 75 |
+
</script>
|
| 76 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 77 |
</body>
|
| 78 |
</html>
|