Microsoft Windows™ :<

This commit is contained in:
Lucas Schumacher 2024-07-31 21:36:48 -04:00
parent b3dbd23a8e
commit 1e61052ec1

View File

@ -5,6 +5,7 @@ import (
"html/template"
"log"
"net/http"
"path/filepath"
"github.com/go-chi/chi/v5"
)
@ -26,15 +27,15 @@ func executeTemplate(w http.ResponseWriter, filepath string) {
}
func homeHandler(w http.ResponseWriter, r *http.Request) {
path := "templates/home.gohtml"
path := filepath.Join("templates", "home.gohtml")
executeTemplate(w, path)
}
func contactHandler(w http.ResponseWriter, r *http.Request) {
path := "templates/contact.gohtml"
path := filepath.Join("templates", "contact.gohtml")
executeTemplate(w, path)
}
func faqHandler(w http.ResponseWriter, r *http.Request) {
path := "templates/faq.gohtml"
path := filepath.Join("templates", "faq.gohtml")
executeTemplate(w, path)
}