update webpage

This commit is contained in:
Akbar Rahman 2023-12-27 23:36:47 +00:00
parent d4b43b364a
commit 2b844a899f
Signed by: alvierahman90
GPG Key ID: 6217899F07CA2BDF

View File

@ -1,3 +1,12 @@
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" href="https://alv.cx/styles.css" />
<title>glass | alv.cx</title>
</head>
<body>
<h1>find glass in an image!</h1>
<img id="img" src="" />
<p id="statusline">submit an image to get started!</p>
@ -6,12 +15,15 @@
<button type="submit" id="submit">submit</button>
</form>
<p> built with ❤ and adequate amounts of care by <a href="https://alv.cx">alv</a></p>
<script>
const form = document.getElementById("form");
const img = document.getElementById("img");
const statusline = document.getElementById("statusline");
async function handleSubmit(ev) {
statusline.innerHTML = "SUBMITTING"
ev.preventDefault();
const form = ev.currentTarget;
const data = new FormData(form);
@ -38,3 +50,4 @@
form.addEventListener('submit', handleSubmit)
</script>
</body>