From 566b0c85d8a12ee83dd537cdddeeaeade81e93e4 Mon Sep 17 00:00:00 2001 From: Patrick Altman Date: Fri, 22 Jul 2016 11:59:54 -0400 Subject: [PATCH] Use form instead of a tag Thanks to PR #55 by @jhotujec for this --- docs/usage.md | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/docs/usage.md b/docs/usage.md index 7276f3c..f28807c 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -50,9 +50,10 @@ See [Template tags](./templatetags.md) for detail on pinax-announcements templat Add this markup to show a "Dismiss" link if available: {% if announcement.dismiss_url %} - - Clear - +
+ {% csrf_token %} + +
{% endif %} ### Dismissal with Eldarion AJAX @@ -74,5 +75,3 @@ This of course is optional. You can roll your own JavaScript handling as the view also returns data in addition to rendered HTML. Furthermore, if you don't want `ajax` at all the view will handle a regular `POST` and perform a redirect. - -