Ticket #9268: comments_doc.2.diff

File comments_doc.2.diff, 1.3 KB (added by Karen Tracey, 16 years ago)

Better docs diff

  • docs/ref/contrib/comments/index.txt

     
    175175
    176176    <form action="{% comment_form_target %}" method="POST">
    177177
     178Specifying the redirect page after comment post
     179-----------------------------------------------
     180
     181To specify the page you want to redirect to after the comment has been
     182posted, you can include a hidden tag called ``next`` in your comment form::
     183
     184    <input type="hidden" name="next" value="page_to_redirect" />
     185
     186Redirecting after a preview or error
     187~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     188
     189If you use the comment preview, or an error occurs in your comment post,
     190you will be taken to the template named ``comments/preview.html``. The value you specified for ``next``
     191on your post page isn't automatically carried over to the preview page.
     192
     193You need to again specify the redirect page with a hidden form tag::
     194
     195    <input type="hidden" name="next" value="{{ data.next }}" />
     196
     197``data`` contains all of the posted values from the original comment post
     198page. ``data.next`` gives us the value of ``next``.
     199
    178200Notes on the comment form
    179201-------------------------
    180202
Back to Top