summaryrefslogtreecommitdiff
path: root/examples/simpleblog/templates
diff options
context:
space:
mode:
Diffstat (limited to 'examples/simpleblog/templates')
-rw-r--r--examples/simpleblog/templates/default.html12
-rw-r--r--examples/simpleblog/templates/index.html14
-rw-r--r--examples/simpleblog/templates/post.html6
-rw-r--r--examples/simpleblog/templates/postitem.html4
-rw-r--r--examples/simpleblog/templates/posts.html4
5 files changed, 29 insertions, 11 deletions
diff --git a/examples/simpleblog/templates/default.html b/examples/simpleblog/templates/default.html
index c411976..01ed20e 100644
--- a/examples/simpleblog/templates/default.html
+++ b/examples/simpleblog/templates/default.html
@@ -4,16 +4,16 @@
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
- <title>SimpleBlog - $title</title>
- <link rel="stylesheet" type="text/css" href="$root/css/default.css" />
+ <title>SimpleBlog - $title$</title>
+ <link rel="stylesheet" type="text/css" href="/css/default.css" />
</head>
<body>
- <h1>SimpleBlog - $title</h1>
+ <h1>SimpleBlog - $title$</h1>
<div id="navigation">
- <a href="$root/index.html">Home</a>
- <a href="$root/posts.html">All posts</a>
+ <a href="/index.html">Home</a>
+ <a href="/posts.html">All posts</a>
</div>
- $body
+ $body$
</body>
</html>
diff --git a/examples/simpleblog/templates/index.html b/examples/simpleblog/templates/index.html
new file mode 100644
index 0000000..4978949
--- /dev/null
+++ b/examples/simpleblog/templates/index.html
@@ -0,0 +1,14 @@
+<div id="posts">
+ <h1>Recent posts</h1>
+ <ul>
+ $posts$
+ </ul>
+ <a href="/posts.html">All posts...</a>
+</div>
+
+<div class="about">
+ <h1>About</h1>
+ <p>
+ This is a sample blog for educational purposes.
+ </p>
+</div>
diff --git a/examples/simpleblog/templates/post.html b/examples/simpleblog/templates/post.html
index 46797a4..e2864ba 100644
--- a/examples/simpleblog/templates/post.html
+++ b/examples/simpleblog/templates/post.html
@@ -1,4 +1,4 @@
-<h1>$title</h1>
-by <em>$author</em> on <strong>$date</strong>
+<h1>$title$</h1>
+by <em>$author$</em> on <strong>$date$</strong>
-$body
+$body$
diff --git a/examples/simpleblog/templates/postitem.html b/examples/simpleblog/templates/postitem.html
index 0e62418..19c954b 100644
--- a/examples/simpleblog/templates/postitem.html
+++ b/examples/simpleblog/templates/postitem.html
@@ -1,4 +1,4 @@
<li>
- <a href="$root/$url">$title</a>
- - <em>$date</em> - by <em>$author</em>
+ <a href="/$url$">$title$</a>
+ - <em>$date$</em> - by <em>$author$</em>
</li>
diff --git a/examples/simpleblog/templates/posts.html b/examples/simpleblog/templates/posts.html
new file mode 100644
index 0000000..2bec161
--- /dev/null
+++ b/examples/simpleblog/templates/posts.html
@@ -0,0 +1,4 @@
+<h1>All posts</h1>
+<ul>
+ $posts$
+</ul>