You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
caddy-hugo2/frontend/templates/author.html.tmpl

44 lines
921 B

<html>
<head>
</head>
<body>
{{ $timeFormat := "Jan _2 15:04:05" }}
<p>Create content:</p>
<form action="/hugo/edit/new" method="POST">
<label>Name: <input type="text" name="name" /></label>
<select name="type">
{{- range .ContentTypes }}
<option value="{{ . }}">{{ . }}</option>
{{- end }}
</select>
<input type="submit" />
</form>
<p>Edit content:</p>
<table>{{ range .Content }}
<tr>
{{ if .Metadata }}
<td>
<a href="/hugo/edit/{{ .Filename }}">
{{ .Metadata.Title }}
</a>
</td>
<td>
{{ .Metadata.Date.Format $timeFormat }}
{{ if not (.Metadata.Lastmod.Equal .Metadata.Date) }}
(last modified {{.Metadata.Lastmod.Format $timeFormat }})
{{end}}
</td>
{{ else }}
<td>
<a href="/hugo/edit/{{ .Filename }}">
{{ .Filename }}
</a>
</td>
<td>(unable to load metadata)</td>
{{ end }}
</tr>
{{- end }}
</table>
</body>
</html>