Fix tags page generation

parent df5a5ad0
......@@ -24,13 +24,15 @@
(colt config))
(define (gen-content tag)
(define-syntax-rule (->url url-name)
(format #f "/archives/~a" (uri-decode url-name)))
(let ((posts (get-posts-by-tag tag)))
(tpl->html
`(div (@ (class "blog-post-content"))
(h2 "Articles contains tag: "
(font (@ (class "red-text")) ,tag))
,(map (lambda (p)
`(p (a (@ (href ,(string-append "/articles/" (post-url-name p))))
`(p (a (@ (href ,(->url (post-url-name p))))
,(post-title p))))
posts)))))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment