akis stuff

This commit is contained in:
2022-07-29 15:35:19 +03:00
parent 2791e68131
commit 9b956bd505
3 changed files with 71 additions and 0 deletions

View File

@@ -29,6 +29,15 @@ func main() {
}
tmpl.Execute(w, data)
})
tmpl_form := template.Must(template.ParseFiles("static/form.html"))
http.HandleFunc("/form/", func(w http.ResponseWriter, r *http.Request) {
data := StaticThingy{
Port: port,
}
tmpl_form.Execute(w, data)
})
http.HandleFunc("/api/", func(w http.ResponseWriter, r *http.Request) {
io.WriteString(w, "welcome to hell")
})