major UI/UX improvements

Signed-off-by: ari melody <ari@arimelody.me>
This commit is contained in:
ari melody 2024-03-18 15:04:04 +00:00
parent 93539c8376
commit 6efd47c6c6
17 changed files with 739 additions and 458 deletions

View file

@ -9,6 +9,7 @@ import (
"net/http"
"log"
"strings"
"time"
"github.com/gomarkdown/markdown"
"github.com/gomarkdown/markdown/html"
@ -37,7 +38,12 @@ var templates = template.Must(template.ParseFiles(
func web_handler(writer http.ResponseWriter, req *http.Request) {
uri := req.URL.Path
fmt.Printf("%s %s (%s)\n", req.Method, req.URL.Path, req.Header["User-Agent"][0])
fmt.Printf("[%s] %s %s (%s)\n",
time.Now().Format(time.UnixDate),
req.Method,
req.URL.Path,
req.Header["User-Agent"][0],
)
if req.URL.Path == "/" {
index_handler(writer, req)