36 lines
1.3 KiB
HTML
36 lines
1.3 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="de">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>xXx Sphere</title>
|
|
<link rel="stylesheet" href="/css/variables.css">
|
|
<link rel="stylesheet" href="/css/style.css">
|
|
<link rel="icon" href="/img/icon.png" type="image/png">
|
|
</head>
|
|
<body>
|
|
<img src="img/icon.png" alt="Icon">
|
|
<h1>Kinky Games und Communities</h1>
|
|
<div id="authButtons" style="display:flex; gap:1rem;">
|
|
<a class="btn" href="/login.html">Anmelden</a>
|
|
<a class="btn" href="/registration.html" style="background:#0f3460;">Registrieren</a>
|
|
</div>
|
|
|
|
<div id="fillerMsg" class="message" style="max-width:320px;"></div>
|
|
|
|
<script>
|
|
fetch('/login/me')
|
|
.then(r => r.ok ? r.json() : null)
|
|
.then(user => {
|
|
if (!user) return;
|
|
const btns = document.getElementById('authButtons');
|
|
btns.insertAdjacentHTML('beforebegin',
|
|
`<p style="text-align:center;">Willkommen zurück, <strong style="color:var(--color-text);">${user.name}</strong></p>`
|
|
);
|
|
btns.innerHTML = '<a class="btn" href="/userhome.html">Betreten</a>';
|
|
})
|
|
.catch(() => {});
|
|
</script>
|
|
</body>
|
|
</html>
|