This commit is contained in:
17
handlers/mainPage.go
Normal file
17
handlers/mainPage.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package handlers
|
||||
|
||||
import (
|
||||
"html/template"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
type MainPage struct {
|
||||
}
|
||||
|
||||
func UpdateMainPage(w http.ResponseWriter, r *http.Request) {
|
||||
w.Header().Set("Content-Type", "text/html; charset=utf-8")
|
||||
tmpl := template.Must(
|
||||
template.New("index.html").ParseFiles("templates/index.html"),
|
||||
)
|
||||
tmpl.Execute(w, nil)
|
||||
}
|
Reference in New Issue
Block a user