flounder

A simple gemini site builder
Log | Files | Refs | README | LICENSE

commit cd39b4e60d52866ec16cde24c9b17d75287336d9
parent f603adbbef0f6f987fedc941cbc34ce95caabffe
Author: alex wennerberg <alex@alexwennerberg.com>
Date:   Wed,  6 Jan 2021 21:55:25 -0800

use url for stylesheet

Diffstat:
Mhttp.go | 4----
Mtemplates/user_page.html | 2+-
2 files changed, 1 insertion(+), 5 deletions(-)

diff --git a/http.go b/http.go @@ -552,10 +552,6 @@ func userFile(w http.ResponseWriter, r *http.Request) { renderDefaultError(w, http.StatusForbidden) return } - if r.URL.Path == "/style.css" { - http.ServeFile(w, r, path.Join(c.TemplatesDirectory, "static/style.css")) - return - } if r.URL.Path == "/gemlog/atom.xml" && os.IsNotExist(err) { w.Header().Set("Content-Type", "application/atom+xml") // TODO set always somehow diff --git a/templates/user_page.html b/templates/user_page.html @@ -4,7 +4,7 @@ <meta charset="utf-8" /> <title>{{.PageTitle }}</title> <meta name="viewport" content="width=device-width" /> - <link rel="stylesheet" type="text/css" href="/style.css" /> + <link rel="stylesheet" type="text/css" href="https://flounder.online/style.css" /> <link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>{{.Favicon}}</text></svg>"> </head> <body>