From 439cbeaa684ce881db000d6a01f70930c426ac7f Mon Sep 17 00:00:00 2001
From: Jannis Leidel <jannis@leidel.info>
Date: Thu, 16 Jun 2011 16:34:02 +0000
Subject: [PATCH] Fixed #16031 -- Corrected comments template examples. Thanks,
 teraom.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16412 bcc190cf-cafb-0310-a4f2-bffc1f526a37
---
 docs/ref/contrib/comments/example.txt | 17 ++++++++++-------
 docs/ref/contrib/comments/index.txt   | 19 ++++++++++++-------
 2 files changed, 22 insertions(+), 14 deletions(-)

diff --git a/docs/ref/contrib/comments/example.txt b/docs/ref/contrib/comments/example.txt
index 921fe03ffa..253701b8da 100644
--- a/docs/ref/contrib/comments/example.txt
+++ b/docs/ref/contrib/comments/example.txt
@@ -103,13 +103,16 @@ But let's look at a simple example::
   <!-- A context variable called form is created with the necessary hidden
   fields, timestamps and security hashes -->
   <table>
-  <form action="{% comment_form_target %}" method="post">
-    {{ form }}
-    <tr>
-      <td></td>
-      <td><input type="submit" name="preview" class="submit-post" value="Preview"></td>
-    </tr>
-  </form>
+    <form action="{% comment_form_target %}" method="post">
+      {% csrf_token %}
+      {{ form }}
+      <tr>
+        <td colspan="2">
+          <input type="submit" name="submit" value="Post">
+          <input type="submit" name="preview" value="Preview">
+        </td>
+      </tr>
+    </form>
   </table>
 
 Flagging
diff --git a/docs/ref/contrib/comments/index.txt b/docs/ref/contrib/comments/index.txt
index 817871e976..7072ed14ac 100644
--- a/docs/ref/contrib/comments/index.txt
+++ b/docs/ref/contrib/comments/index.txt
@@ -218,13 +218,18 @@ you can use in the template::
 A complete form might look like::
 
     {% get_comment_form for event as form %}
-    <form action="{% comment_form_target %}" method="post">
-      {{ form }}
-      <tr>
-        <td></td>
-        <td><input type="submit" name="preview" class="submit-post" value="Preview"></td>
-      </tr>
-    </form>
+    <table>
+      <form action="{% comment_form_target %}" method="post">
+        {% csrf_token %}
+        {{ form }}
+        <tr>
+          <td colspan="2">
+            <input type="submit" name="submit" value="Post">
+            <input type="submit" name="preview" value="Preview">
+          </td>
+        </tr>
+      </form>
+    </table>
 
 Be sure to read the `notes on the comment form`_, below, for some special
 considerations you'll need to make if you're using this approach.