use relative links instead of absolute to allow subpath installation

This commit is contained in:
Tobias Ollive 2021-12-10 18:24:22 +01:00
parent 5183db5829
commit 513d05d8b0
2 changed files with 8 additions and 4 deletions

View file

@ -66,19 +66,23 @@ router.get("/", function (req, res) {
})
router.get("/demo", function (req, res) {
url = req.header("host") + req.baseUrl
res.render("index.jade", {
pageTitle: "Post-it - demo",
headerBarUrl: headerBarUrl,
logoUrl: logoUrl,
url: url,
demo: true
})
})
router.get("/:id", function (req, res) {
url = req.header("host") + req.baseUrl
res.render("index.jade", {
pageTitle: "Post-it - " + req.params.id,
headerBarUrl: headerBarUrl,
logoUrl: logoUrl
logoUrl: logoUrl,
url: url
})
})