about summary refs log tree commit diff stats
path: root/templates/page.templ
diff options
context:
space:
mode:
Diffstat (limited to 'templates/page.templ')
-rw-r--r--templates/page.templ16
1 files changed, 11 insertions, 5 deletions
diff --git a/templates/page.templ b/templates/page.templ
index e5cb073..294b73e 100644
--- a/templates/page.templ
+++ b/templates/page.templ
@@ -1,9 +1,11 @@
 package templates
 
 import (
-	"io/fs"
-
+	"context"
 	"go.alanpearce.eu/website/internal/config"
+	"io"
+	"io/fs"
+	"net/url"
 )
 
 var (
@@ -70,7 +72,7 @@ templ Page(site *config.Config, page PageSettings) {
 			<footer>
 				Content is
 				<a rel="license" href="http://creativecommons.org/licenses/by/4.0/">CC BY 4.0</a>.
-				<a href="https://git.alanpearce.eu/go.alanpearce.eu/website/">Site source code</a> is
+				<a href="https://git.alanpearce.eu/website/">Site source code</a> is
 				<a href="https://opensource.org/licenses/MIT">MIT</a>
 			</footer>
 			@counter(site, page.Path, page.Title)
@@ -86,8 +88,12 @@ templ Page(site *config.Config, page PageSettings) {
 	</html>
 }
 
-func mkURL(u config.URL, path string, title string) string {
-	q := u.Query()
+func mkURL(original config.URL, path string, title string) string {
+	ou := *original.URL
+	u := config.URL{
+		URL: &ou,
+	}
+	q := url.Values{}
 	q.Add("p", path)
 	q.Add("t", title)
 	u.RawQuery = q.Encode()