summaryrefslogtreecommitdiff
path: root/tpls
diff options
context:
space:
mode:
Diffstat (limited to 'tpls')
-rw-r--r--tpls/master.tpl4
-rw-r--r--tpls/msg.tpl9
2 files changed, 11 insertions, 2 deletions
diff --git a/tpls/master.tpl b/tpls/master.tpl
index b675598..4e2b90f 100644
--- a/tpls/master.tpl
+++ b/tpls/master.tpl
@@ -1,9 +1,9 @@
<html>
<head>
- <title>{{template "title"}} – mailremind</title>
+ <title>{{template "title" .}} – mailremind</title>
</head>
<body>
- <h1>{{template "title"}}</h1>
+ <h1>{{template "title" .}}</h1>
<div class="content">
{{template "content" .}}
diff --git a/tpls/msg.tpl b/tpls/msg.tpl
new file mode 100644
index 0000000..f7e75f3
--- /dev/null
+++ b/tpls/msg.tpl
@@ -0,0 +1,9 @@
+{{define "title"}}{{.Title}}{{end}}
+
+{{define "content"}}
+ {{if .Class}}
+ <div class="{{.Class}}">{{.Msg}}</div>
+ {{else}}
+ <div>{{.Msg}}</div>
+ {{end}}
+{{end}} \ No newline at end of file