2020-01-24 12:47:52 -07:00
|
|
|
{{$pathParts := splitList "/" .OriginalReq.URL.Path}}
|
|
|
|
{{$markdownFilename := default "index" (slice $pathParts 2 | join "/")}}
|
|
|
|
{{$markdownFilePath := printf "/docs/markdown/%s.md" $markdownFilename}}
|
2021-09-15 11:57:02 -06:00
|
|
|
{{if not (fileExists $markdownFilePath)}}{{httpError 404}}{{end}}
|
2020-01-24 12:47:52 -07:00
|
|
|
{{$markdownFile := (include $markdownFilePath | splitFrontMatter)}}
|
2020-02-28 15:15:13 -07:00
|
|
|
{{$title := default $markdownFilename $markdownFile.Meta.title}}
|
2020-01-24 12:47:52 -07:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html>
|
|
|
|
<head>
|
2020-02-28 15:15:13 -07:00
|
|
|
<title>{{$title}} — Caddy Documentation</title>
|
2023-12-11 10:07:34 -07:00
|
|
|
{{import "/old/includes/docs/head.html"}}
|
2023-08-11 12:03:17 -04:00
|
|
|
{{template "docs-head"}}
|
2020-02-28 15:15:13 -07:00
|
|
|
<meta property="og:title" content="{{$title}} - Caddy Documentation">
|
|
|
|
<meta name="twitter:title" value="{{$title}} - Caddy Documentation">
|
2020-01-24 12:47:52 -07:00
|
|
|
</head>
|
|
|
|
<body>
|
2023-12-11 10:07:34 -07:00
|
|
|
{{include "/old/includes/docs/header.html"}}
|
2020-01-24 12:47:52 -07:00
|
|
|
<main>
|
2023-12-11 10:07:34 -07:00
|
|
|
{{include "/old/includes/docs/nav.html"}}
|
2020-01-24 12:47:52 -07:00
|
|
|
<div class="article-container">
|
2020-03-30 15:38:40 -06:00
|
|
|
<div class="paper" id="paper1"></div>
|
|
|
|
<div class="paper" id="paper2"></div>
|
2021-06-02 15:16:15 -06:00
|
|
|
<div class="paper paper3">
|
|
|
|
<article>{{markdown $markdownFile.Body}}</article>
|
|
|
|
</div>
|
2020-01-24 12:47:52 -07:00
|
|
|
</div>
|
|
|
|
<div class="sidebar"></div>
|
|
|
|
</main>
|
2023-12-11 10:07:34 -07:00
|
|
|
{{include "/old/includes/footer.html"}}
|
2020-01-24 12:47:52 -07:00
|
|
|
</body>
|
|
|
|
</html>
|