package main import ( "io/ioutil" "net/http" ) func helpHandler(w http.ResponseWriter, r *http.Request) { content, err := ioutil.ReadFile("./help.html") if err != nil { http.Error(w, err.Error(), http.StatusInternalServerError) } w.Header().Set("Content-Type", "text/html; charset=utf-8") w.Write(content) }