#9977: CSRFMiddleware needs template tag
------------------------------------+---------------------------------------
          Reporter:  bthomas        |         Owner:  nobody
            Status:  new            |     Milestone:        
         Component:  Uncategorized  |       Version:  1.0   
        Resolution:                 |      Keywords:  csrf  
             Stage:  Unreviewed     |     Has_patch:  1     
        Needs_docs:  1              |   Needs_tests:  0     
Needs_better_patch:  1              |  
------------------------------------+---------------------------------------
Comment (by Rob Hudson <[email protected]>):

 I've done only a few things with patch named '9977.diff':

 * Converted \r\n newlines to \n newlines.
 * Removed an unused import.
 * Added the __init__.py to the templatetags directory.
 * If there is no CSRF token in the context it outputs nothing.
 * Removed the id attribute from the input element.

 I'll try to work up some docs and tests for the next patch.

 Regarding the input tag's id attribute... the way the middleware worked is
 if it output anything after the first one the id tag was empty.  Since the
 template tag is a new feature (and is opt-in, in a sense), it would make
 sense to me that this doesn't need to maintain this behavior.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/9977#comment:4>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to