Initial commit
This commit is contained in:
33
index.html
Normal file
33
index.html
Normal file
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en" data-bs-theme="dark">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>File Uploader</title>
|
||||
<link rel="stylesheet" href="/static/bootstrap.min.css">
|
||||
</head>
|
||||
<body class="bg-dark text-light">
|
||||
<div class="container py-5">
|
||||
<h2>Upload a File</h2>
|
||||
<form action="/upload" method="POST" enctype="multipart/form-data" class="row g-3 mb-4">
|
||||
<div class="col-9">
|
||||
<input type="file" name="file" class="form-control" required>
|
||||
</div>
|
||||
<div class="col-3">
|
||||
<button class="btn btn-primary w-100">Upload</button>
|
||||
</div>
|
||||
</form>
|
||||
<h3>Files</h3>
|
||||
<ul class="list-group">
|
||||
{{range .Files}}
|
||||
<li class="list-group-item d-flex justify-content-between">
|
||||
<a href="/files/{{.Name}}" class="text-light">{{.Name}}</a>
|
||||
<span class="badge bg-secondary">{{.Size | formatBytes}}</span>
|
||||
</li>
|
||||
{{else}}
|
||||
<li class="list-group-item">No files yet</li>
|
||||
{{end}}
|
||||
</ul>
|
||||
<p class="mt-4 text-center"><a href="/dashboard" class="btn btn-outline-info">Go to Dashboard</a></p>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user