Commit 7880d999 authored by Jannis Leidel's avatar Jannis Leidel
Browse files

[1.3.X] Fixed #16031 -- Corrected comments template examples. Thanks, teraom.

Backport from trunk (r16412).

git-svn-id: http://code.djangoproject.com/svn/django/branches/releases/1.3.X@16421 bcc190cf-cafb-0310-a4f2-bffc1f526a37
parent 25ee9b49
Loading
Loading
Loading
Loading
+10 −7
Original line number Diff line number Diff line
@@ -104,10 +104,13 @@ But let's look at a simple example::
  fields, timestamps and security hashes -->
  <table>
    <form action="{% comment_form_target %}" method="post">
      {% csrf_token %}
      {{ form }}
      <tr>
      <td></td>
      <td><input type="submit" name="preview" class="submit-post" value="Preview"></td>
        <td colspan="2">
          <input type="submit" name="submit" value="Post">
          <input type="submit" name="preview" value="Preview">
        </td>
      </tr>
    </form>
  </table>
+12 −7
Original line number Diff line number Diff line
@@ -218,13 +218,18 @@ you can use in the template::
A complete form might look like::

    {% get_comment_form for event as form %}
    <table>
      <form action="{% comment_form_target %}" method="post">
        {% csrf_token %}
        {{ form }}
        <tr>
        <td></td>
        <td><input type="submit" name="preview" class="submit-post" value="Preview"></td>
          <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.