make it cleaner and easier
This commit is contained in:
2
main.go
2
main.go
@@ -17,7 +17,7 @@ func pageHandler(w http.ResponseWriter, r *http.Request) {
|
|||||||
filepath.Join("templates/layout.html"),
|
filepath.Join("templates/layout.html"),
|
||||||
filepath.Join("templates/header.html"),
|
filepath.Join("templates/header.html"),
|
||||||
filepath.Join("templates/footer.html"),
|
filepath.Join("templates/footer.html"),
|
||||||
filepath.Join("templates/"+path+".html"),
|
filepath.Join("pages/"+path+".html"),
|
||||||
)
|
)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
http.NotFound(w, r)
|
http.NotFound(w, r)
|
||||||
|
|||||||
Reference in New Issue
Block a user