created page

This commit is contained in:
array-in-a-matrix 2024-03-20 23:38:59 -04:00
parent c513493917
commit 27f25456c7
2 changed files with 36 additions and 0 deletions

3
src/pages/login.astro Normal file
View File

@ -0,0 +1,3 @@
---
import '../styles/global.css';
---

33
src/pages/register.astro Normal file
View File

@ -0,0 +1,33 @@
---
import "../styles/theme.css";
if (Astro.request.method === "POST") {
try {
const data = await Astro.request.formData();
// Do something with the data
} catch (error) {
if (error instanceof Error) {
console.error(error.message);
}
}
}
---
<div>
<h1>Register</h1>
<form method="POST">
<label>Username:</label>
<input type="text" name="username" required />
<label>Email:</label>
<input type="email" name="email" required />
<label>Password:</label>
<input type="password" name="password" required minlength="6" />
<button>Submit</button>
</form>
</div>
<style>
:root {
background-color: var(--background);
}
</style>