i suck
sophuwu sophie@skisiel.com
Fri, 20 Dec 2024 03:48:27 +0100
2 files changed,
2 insertions(+),
2 deletions(-)
M
blogs.go
→
blogs.go
@@ -88,7 +88,7 @@ }
// BlogHandler handles requests to the blog page and individual blog posts func BlogHandler(w http.ResponseWriter, r *http.Request) { - path := strings.TrimPrefix(r.URL.RawPath, "/blog/") + path := strings.TrimPrefix(r.URL.RawQuery, "blog=") if path == "" { blogs, err := GetBlogs() if CheckHttpErr(err, w, r, 500) {
M
webhome/templates/blogs.html
→
webhome/templates/blogs.html
@@ -14,7 +14,7 @@ </p>
<hr> {{- range .blogs -}} <section class="blog-row"> - <a href="/blog/{{- .ID -}}" class="ref-name">{{- .Title -}}</a> + <a href="/blog/?blog={{- .ID -}}" class="ref-name">{{- .Title -}}</a> <span class="date">{{- .Date -}}</span> <p >{{- .Desc -}}</p> </section>