aboutsummaryrefslogtreecommitdiffstats
path: root/templates/edit_post.html
diff options
context:
space:
mode:
Diffstat (limited to 'templates/edit_post.html')
-rw-r--r--templates/edit_post.html30
1 files changed, 30 insertions, 0 deletions
diff --git a/templates/edit_post.html b/templates/edit_post.html
new file mode 100644
index 0000000..9154e3d
--- /dev/null
+++ b/templates/edit_post.html
@@ -0,0 +1,30 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <title>Edit {{ post.title }}</title>
+ </head>
+ <body>
+ <h1>Edit post</h1>
+ <form id="new_post" name="post" method="post" action="/posts/update">
+ <input type="hidden" name="id" value="{{ post.id }}">
+ <div class="field">
+ <label>Title:</label>
+ <input type="text" name="title" value="{{ post.title }}">
+ </div>
+
+ <div class="field">
+ <label>Contents:</label>
+ <textarea name="body">{{ post.body }}</textarea>
+ </div>
+
+ <div class="field">
+ <input type="checkbox" checked="{{ post.published }}">
+ <label>Published</label>
+ </div>
+
+ <div class="actions">
+ <input type="submit" value="Save">
+ </div>
+ </form>
+ </body>
+</html>